- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-20-2017 07:51 PM
Hi,
I would like to hide "New" button from "All" list based on the Module Name.
For exaample, if the module name is "My Incidents", it will show all my incidents with "New" button as list view by clicking on it.
But, this New button should not be displayed if it is under "My Incidents" list.
Could anyone help in this?
thanks
VG
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-22-2017 12:04 AM
Sorry, one correction in my reply
if RP.getParameterValue('sysparm_userpref_module') =='sys_id'
{
return false
}
else
{
if (Existing condition value of New button)
return true
else
return false
}
regards
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-20-2017 08:00 PM
We can do this by Views, have a separate view for My Incidents and add a condition on UI Action to show only for certain views
please refer for getting view name in UI Action How to get View Name on Server side UI ACtion .

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-20-2017 08:22 PM
Please have below useful link.
you cam modify the UI Actions to disable the New button.
Using Access Control Rules - ServiceNow Wiki
Restrict or hide NEW button on incident list by roles doesn't work
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-20-2017 08:31 PM
Hi Shishir.
thanks for your help.
we have a separate UI action to show this "New" button in the list. if set active is false, then this new button does not display to all modules (showing List) related with this "Incident" application.
I would like to hide this "New" button for a particular module say "My incidents".
Can I get the current module name in the "UI Action"? if yes, this can be used as condition to show / hide this button.
thanks
VG
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-20-2017 08:58 PM
Put RP.getParameterValue('sysparm_userpref_module') == 'ID for module' in the condition statement...