Show/hide button on workspace list page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-04-2025 08:10 AM
Hi Community:
I have a requirement to show the Approve button on the Workspace list page above the list only when the selected records' state is a certain state, eg. awaiting approval. When user select some records that the state is not that one, the Approve button won't be available. In the Action Assignment, I set the Record Conditions as: state is awaiting approval. but the button won't show at all even the selected records' state is correct.
How to show/hide this button?
Thanks a lot
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-05-2025 10:24 AM - last edited 3 weeks ago
Hello,
I've done something similar, but instead of hiding the button, the button is just disabled and you cannot click on it if you select a record that does not match the conditions.
I have 1 declarative action of type List, where I have the following fields set (some fields might not be available on the form, you need to add them).
Record Selection Required = True
Group By = True (you don't need this)
Group = (my specific group where I have the edit button and the close button, you don't need this)
Enable Dynamic Evaluation = True --> docs
Dynamic Record conditions = for example (state != awaiting approval)
Then when the user selects multiple records, if one fails the condition the button is not available
For the enable dynamic evaluation, note that as per documentation:
You may experience slowness and unresponsiveness if this feature is used in combination with theSelect All, which selects all records in a list, as conditions must be evaluated for all the selected records.
What I do, is also setting a max number of records the user can select, on my situation I have the action implemented as a client script because I need to do some ajax operations, so I use the count variable from the action modal :
I hope this helps 🙂
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hello, I need your help.
I have set Dynamic Record Evaluation to true and configured the required conditions. It works correctly when I select up to 100 records on a single page view. However, it does not work when I use the Select All button.
When I use Select All, I have verified that all the selected records meet the configured conditions. I am 100% sure the conditions are satisfied, but I still receive an error.
I have attached a screenshot for reference. Could you please help me understand why this is happening?
 
 
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hello Rani,
I tried on my PDI (glide-australia-02-11-2026__patch2-04-17-2026) with a very simple button that would just print the sys_id in the logs of each record (Server side), and I got the same issue as you describe, so this must be some kind of protection built it by ServiceNow. I would advise you raise a ticket with support and let us all know what they find.
Remember they do say "You may experience slowness and unresponsiveness if this feature is used in combination with theSelect All, which selects all records in a list, as conditions must be evaluated for all the selected records." , but I was not aware of something else blocking this behaviour, I am also interested to know what SN would answer.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎03-05-2025 11:26 AM
Thank you so much for your quick response. I don't know why in our instance; I can't enable dynamic evaluation. it's not checkable.