How to display and download attachments through Service Portal
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-16-2021 05:18 AM
I am displaying a custom table which has attachments through the Service Portal and am trying to achieve 4 things but am stuck on how to accomplish
1- View attachment when View button clicked
2- Download attachment when download clicked
3- display extension type of attachment onto the list
4- display the size of the attachment onto the list.
- Labels:
-
Service Portal Development
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-16-2021 05:34 AM
Hi,
Can you share the current script how you are showing the above form?
Is it via UI page or widget?
please share those
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-16-2021 05:43 AM
Through a widget. Currently its a simple server side script querying the custom table and displaying values on the list. But where I am stuck is the attachments field information as the custom table attachment field I cannot see the extension type data as well as size. Also how to create/download attachments through the portal side interface.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-16-2021 06:09 AM
Hi,
not much sure on the view part
but for download part you can add the link to attachment record for each button for respective record and once user clicks that download button it would download the file
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎04-16-2021 06:23 AM
Thanks Ankur,
I am able to get download working.
1- View attachment when View button clicked
2- Download attachment when download clicked - COMPLETED
3- display extension type of attachment onto the list
4- display the size of the attachment onto the list.