Add hyperlink to form and open excel file on clicking it

Servicenow Use4
Kilo Guru

Hello All,

I have an excel file. I need to have a hyperlink in the form. On clicking that hyperlink, that excel file should be opened. I searched on community and found varying answers related to this but couldn't get a clear idea as to what has to be done....

Can anyone throw some light on

1. how to add hyperlink to a form

2. On its click, open an excel file.... please note.. i just want it to get opened..and not save the file.

 

Many thanks in advance!

 

1 ACCEPTED SOLUTION

Hi,

For point 1 - if you want that file to be shown via URL then you need to store it in ServiceNow i.e. attach to some or other table record.

For point 2 - it depends on the browser configuration whether it is set auto-download or only Open

what type of form you are trying to show to user?

Regards
Ankur

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

View solution in original post

15 REPLIES 15

Ankur Bawiskar
Tera Patron
Tera Patron

Hi,

Few questions

1) where is this excel file stored? is it on some record

2) on click of the link it will ask user 2 options either to open or download based on the browse preference

Regards
Ankur

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

Hi!

1. As of now, it is stored in my local system. I also need some assistance on where should I store the file.

2. If the user gets an option to open or download, well, it is his/her choice what action is to be taken. But I think most users will just open it..and not download. It should just not get auto-downloaded is where my concern lies.

 

Thanks!

Hi,

For point 1 - if you want that file to be shown via URL then you need to store it in ServiceNow i.e. attach to some or other table record.

For point 2 - it depends on the browser configuration whether it is set auto-download or only Open

what type of form you are trying to show to user?

Regards
Ankur

Regards,
Ankur
✨ Certified Technical Architect  ||  ✨ 9x ServiceNow MVP  ||  ✨ ServiceNow Community Leader

I have created a custom table with, say, 10 fields.

What the user would see is just a view of the form having 5 fields that are of use to him.

Now, to be able to fill in the form, he needs some extra information (that I have in the form of an excel sheet) that would be of help. For this reason, I need to provide a hyperlink on the form. On clicking that, that excel sheet should open.