- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-31-2022 11:04 PM
Hi.
I want to control the state of fields on the screen according to the group to
which the logged-in user belongs.
I am using client scripts (onLoad) + business rules (g_scratchpad),
is it possible to use multiple g_scratchpads?
<Here are the requirements I want to achieve>
Users belonging to group A: Make field AAA read-only
Users belonging to group B: Make field BBB read-only
<Referenced site>
https://community.servicenow.com/community?id=community_question&sys_id=d6f7eae2db36ff40414eeeb5ca96...
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-31-2022 11:09 PM
Hi,
yes you can.
But you can merge the logic and store the flag in single scratchpad as well and use it
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-31-2022 11:07 PM
Yes we can have multiple g_scratchpad. in a business rule and check in client scripts. Refer below
https://servicenowgems.com/2016/10/10/understanding-scratchpad-g_scratchpad/
Harish
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-31-2022 11:09 PM
Hi,
yes you can.
But you can merge the logic and store the flag in single scratchpad as well and use it
Regards
Ankur
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-31-2022 11:35 PM
Hi,
Yes. you can use multiple g_scratchpad.