Allow additional attachment extensions to a specific catalog item
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
4 hours ago
Hello everyone, I want to know if there's a possible way to allow extra attachment extensions for one specific catalog item.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 hours ago
Hello @b__ManalK , As per my understanding your requirement is to add attachment with different extensions to a specific service catalog.
There are two ways to do it.
1. Create a new variable "Type- Attachment" this won't restrict you from uploading files with different extensions.
(Note- Hide the show attachment OOTB field from catalog item's portal setting as per your requirement).
2. Use this one line of code in variable attribute "allowed_extensions=your needed file extenstions"
@b__ManalK , Please mark this solution as accepted and Helpful. As it will be helpful for future users and readers.
Best Regards,
Saurabh V.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 hours ago
I used to the system property (glide.attachment.extensions), to define the extensions allowed for all attachments coming from whatever table but , there's that one catalog item that we want to allow extra extensions for it, I tried to the ( allowed_extensions=pdf;csv etc.) methode as you mentioned and add the extra extensions but if they are not already mentioned in sys property they get blocked too.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 hours ago
allowed_extensions is used for attachment variable type on catalog item and should comply with that property.
The system will always checks system property "glide.attachment.extensions"
If you are only allowing doc, pdf and on attachment variable you want docx but that's not present in that system property, it will block.
Note: system property will take the precedence as it's for entire instance and applies globally
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 hours ago
@b__ManalK , If you do it from system properties that change will apply globally for all table and all catalog item. If you want to do it particularly to a single catalog item, I would suggest you to go with the option 1. Create a custom attachment variable and hide the OOTB attachment field from catalog item's portal setting that will be the best here.
If this solution helped you Please Mark this solution as accepted and helpful as it will be helpful for other users and readers as well.
Best Regards.
Saurabh V.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 hours ago