How to display attachments in Announcements on Service Portal?

sweetymiriyala
Giga Contributor

Hi All,

Is there any way to display attachments on announcements which are displayed on Service Portal Banner. I am attaching an attachment in Announcement record and I wanna show the same attachment on Announcement in Service Portal. Is there any way to do so?

Thanks in Advance,

Sweety

1 ACCEPTED SOLUTION

Sateesh Kumar 2
Kilo Guru

Sure you can use attachment directly, using document viewer.

Make sure whether document viewer plugin is activated before trying this.

Use the below as URL instead of the earlier url that I usggested in the screenshot.

/sys_attachment.do?view=true&sys_id=d4b349392fc7401046b6e93df699b65e

Note: Sys_id here is the sys_id of the attachment not announcement.

It allows only few attachment type to view online unsupported file type.

Find more details about document viewer in below link

https://docs.servicenow.com/bundle/newyork-platform-user-interface/page/use/using-forms/concept/Docu...

 

Regards,

Sateesh Kumar Devadoss

View solution in original post

8 REPLIES 8

I have tried it in personal instance with the Document Viewer plugin installed. But , every document is immediately downloading on clicking the link . 

I have tried without installing plugin in client instance, directly gave url of attachment ,

for pdf attachment it is just opening normally without downloading, but for other document formats like word, excel it is downloading on click.

I didn't see any difference though the plugin is installed

Just now , got to know that we have add Use Document Viewer attributes to the table and set Value to True after plugin installation. Now, the document viewer is able to show the attachments without immediately downloading. I will show the client both the ways.

Sateesh Kumar 2
Kilo Guru

Happy to hear that it works I was trying to test that had some troubles and found that there is a limit on size for document viewer, document of size less than 50 MB can only be used in this feature.

 

Mark the appropriate comment as correct if it had solved your issue.

 

Regards,

Sateesh Kumar Devadoss.

I think we can set the document size using some system properties