We've updated the ServiceNow Community Code of Conduct, adding guidelines around AI usage, professionalism, and content violations. Read more

how to hide 'edit' on standard ticket tab Attachment tab

Mike Stockman1
Tera Guru

Im using Standard Ticket on my csp portal and want to modify the standard ticket tab - attachments so that there is not the edit icon. I'm trying to make it where someone cannot change the name of the attachment. 

Where do i go to remove that edit button?

1 ACCEPTED SOLUTION

sanjeet1245
Tera Guru

Hi @Mike Stockman1 
please use below script . create a onload client script on the table you want to remove a edit button 

 

function onLoad() {
   
        var editButton = top.document.querySelector('button[aria-label="Edit Attachments mode"]');
        if (editButton) {
            editButton.style.display = 'none';
        }
}

View solution in original post

5 REPLIES 5

This worked. Thanks!