- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-19-2023 11:52 PM
Hello experts,
I want to make all variables on the RITM and Catalog task read except one variable,
to make variables read-only I have onload client script :
g_form.setVariablesReadOnly(true);
above code making all variables read-only, I want all variables to be read-only except.
How can I achieve this please guide me on this.
thank you.
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-20-2023 12:21 AM
then handle those explicitly i.e. make them editable after that line
g_form.setVariablesReadOnly(true);
g_form.setReadOnly('variable1', false);
g_form.setReadOnly('variable2', false);
If my response helped please mark it correct and close the thread so that it benefits future readers.
Ankur
✨ Certified Technical Architect || ✨ 9x ServiceNow MVP || ✨ ServiceNow Community Leader

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
12-27-2023 01:08 AM
Thank you for marking my response as helpful, if you feel links I shared are helpful please mark my response as accepted as well.
Regards,
Musab