How to hide "Export" Form context menu

hoho
Tera Contributor

I want to hide the "Export" option in the FORM context menu, not in the list view. Does anyone know how to do it? Thank you!

hoho_1-1749007010281.png

 

 

1 ACCEPTED SOLUTION

GlideFather
Tera Patron

Hi there,

you can hide that by commenting out (or modifying elsehow) the UI Macro context_form_header, which I will not recommend you at all, it is OOTB feature and you will get problem with every single instance update...

https://your-instance.service-now.com/nav_to.do?uri=sys_ui_macro.do?sys_id=2ff1c56ca9fe3dba014340c4697b5088

I commented out the lines 97-115:

KamilTEL_0-1749050397439.png

¨

And the result: 

KamilTEL_1-1749050419977.png


ONCE AGAIN: I strongly recommend you NOT to update this, not only as it will cause troubles with instances upgrades (so yearly or half-yearly) but it has hidden the View option from the context menu as well... 


EDIT: you can also change the particular lines to false (100, 104 etc) just for the XML and other options but still this is not a good idea...

Please, let me know if this helped you and if so, please mark this response as solution accepted, thank you

———
/* If my response wasn’t a total disaster ↙️ drop a Kudos or Accept as Solution ↘️ Cheers! */


View solution in original post

1 REPLY 1

GlideFather
Tera Patron

Hi there,

you can hide that by commenting out (or modifying elsehow) the UI Macro context_form_header, which I will not recommend you at all, it is OOTB feature and you will get problem with every single instance update...

https://your-instance.service-now.com/nav_to.do?uri=sys_ui_macro.do?sys_id=2ff1c56ca9fe3dba014340c4697b5088

I commented out the lines 97-115:

KamilTEL_0-1749050397439.png

¨

And the result: 

KamilTEL_1-1749050419977.png


ONCE AGAIN: I strongly recommend you NOT to update this, not only as it will cause troubles with instances upgrades (so yearly or half-yearly) but it has hidden the View option from the context menu as well... 


EDIT: you can also change the particular lines to false (100, 104 etc) just for the XML and other options but still this is not a good idea...

Please, let me know if this helped you and if so, please mark this response as solution accepted, thank you

———
/* If my response wasn’t a total disaster ↙️ drop a Kudos or Accept as Solution ↘️ Cheers! */