- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Hi ,
I have below catalog with mentioned select box type variable . I want to show a field message when " add" is selected on that variable . I have tired the below Onchange catalog client script but couldn't get the result .
Please suggest what changes should I make to achieve this ?
Thank You
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Please select UI Type as All.
Also, could you post a screenshot of whole Client script. I guess this is the only issue - UI Type is not selected as all.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
Please select UI Type as All.
Also, could you post a screenshot of whole Client script. I guess this is the only issue - UI Type is not selected as all.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago
@1_DipikaD Please check once
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
3 weeks ago - last edited 3 weeks ago
Hello @1_DipikaD,
Try the below script:
Applies to: A Catalog Item
UI Type: All
Type: onChange
Variable name: Select your variable (i.e., request_type)
Applies on a Catalog Item view ☑️
Script:
function onChange(control, oldValue, newValue, isLoading) {
if (isLoading || newValue == '') {
return;
}
if (newValue == '1') {
g_form.showFieldMsg('request_type', "This request requires email approval from the Business mgmt", 'info');
} else {
g_form.hideFieldMsg('request_type');
}
}
Please Mark Correct ✔️if this solves your query and also mark Helpful 👍 if you find my response worthy based on the impact.
Regards,
Shruti