- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-18-2025 01:49 AM
Hi All,
Can you please let me know how to meet the requirements below?
Q) there is a catalogue variable which need to trace the link in it.
variable called: X
variable type: rich text label
content: it has 6 hyperlinks one below the other
task need to achieve: there is a check box variable check only needs to check true if all the above hyperlinks has been clicked is there any way to achieve it
Thank you,
Puneet
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-18-2025 07:05 PM
Hope you are doing good.
Did my reply answer your question?
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
02-19-2025 06:15 AM
Hi Ankur,
i have tried above method i was not able to capture the clicks I have added the code below for reference can you help me out where exactly I'm making mistake on the script.
Client control:
Thank you in advance
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-18-2025 02:06 AM - edited 02-18-2025 02:13 AM
difficult to achieve.
But you can use this approach
1) Create hidden string type variable and hide it using UI policy
2) Create a widget and add those links and define onclick function on it, that function will get value of the hidden variable and whenever click is performed it will increment the count. Create variable of type Custom and associate this widget
3) then use onSubmit catalog client script and see what's the count.
If the count is less than 6 then don't allow user to submit
check this link for Step 2
Pass values from a Widget to a Catalog item variable
Basically you can use this syntax in client controller to get and set the variable value
$scope.page.g_form.setValue('var_name', 'yourValue');
$scope.page.g_form.getValue('var_name');
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
02-18-2025 06:39 AM
Hi Ankur,
thank you for suggesting a solution will definitely let you know does this works.
Thank you
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
02-18-2025 07:51 AM
the above has worked for me when I tried.
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
02-18-2025 09:05 AM
Thank you for marking my response as helpful.
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