- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-24-2024 09:44 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-24-2024 10:29 AM - edited ‎10-24-2024 10:36 AM
Hi @SomyaSwaroC
Can you share the code you tried?
You have to write an OnSubmit client script and return 'false' if the value is 'No'
if(g_form.getValue('variable_name') == 'No' ) //replace variablename
return false;
Mark it helpful if this helps you to understand. Accept solution if this give you the answer you're looking for
Kind Regards,
Rohila V
2022-25 ServiceNow Community MVP
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-24-2024 09:51 AM
Hi @SomyaSwaroC ,
add an alert at the beginning to answer the question of what value is detected:
function onSubmit() {
var atgm = g_form.getValue('atgm_user');//replace with your variable name
alert(atgm);
if (atgm == 'false') {
alert(getMessage('You have to be an ATGM user in order to use PDMLink with CREO. You cannot submit this request if you are not an ATGM user.'));
return false;
}
}
If you find it helpful, please mark my answer as correct so that it can useful to others.
Thanks & Regards,
Sumanth Meda
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-24-2024 10:19 AM
still it is not preventing the catalog item request submission.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
‎10-24-2024 10:29 AM - edited ‎10-24-2024 10:36 AM
Hi @SomyaSwaroC
Can you share the code you tried?
You have to write an OnSubmit client script and return 'false' if the value is 'No'
if(g_form.getValue('variable_name') == 'No' ) //replace variablename
return false;
Mark it helpful if this helps you to understand. Accept solution if this give you the answer you're looking for
Kind Regards,
Rohila V
2022-25 ServiceNow Community MVP