I want to display an alert when the size of an attachment exceeds 18MB.

hkriwk1
Tera Contributor

When you create an email from the case form, you can compose it in a new tab.
I want to implement a mechanism where, if you attach a file in that tab and its size exceeds 18MB, a popup appears.
How can these be achieved?

hkriwk1_0-1757473271449.png

 

1 ACCEPTED SOLUTION

Ankur Bawiskar
Tera Patron
Tera Patron

@hkriwk1 

you can use before insert BR on sys_attachment table and block the insert but you can't show the info message.

If my response helped please mark it correct and close the thread so that it benefits future readers.

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

View solution in original post

6 REPLIES 6

Shruti D
Kilo Sage

Hello @hkriwk1,

Please refer below links:
 Attachment size pop up 

Attachment limit properties


Please Mark Correct ✔️
 if this solves your query and also mark Helpful 👍
 if you find my response worthy based on the impact.

Regards,
Shruti

Ankur Bawiskar
Tera Patron
Tera Patron

@hkriwk1 

you can use before insert BR on sys_attachment table and block the insert but you can't show the info message.

If my response helped please mark it correct and close the thread so that it benefits future readers.

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

After looking into it a bit more, I found this.

https://www.servicenow.com/community/developer-forum/how-to-customize-the-send-button-of-the-email-c...

“email_client.do” seemed to be black-boxed.

@hkriwk1 

so ideally there is no way to handle this right?

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