need to change rich text label value on change of script
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
an hour ago
Hi There,
i have a rich text field and it should populate only when variable erg is selected.
also that rich text should have the selected erg value in it and then populate but its working. i have tried on change client scripts but the result is nill.
please let me know if anyone has any idea how to crack it.
Thankyou
Priyanka.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
an hour ago
share the client script, seems something wrong in it.
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
an hour ago
Hi Ankur,
below is the client script.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
an hour ago
it's onChange catalog client script right?
try this and share what came in alert
function onChange(control, oldValue, newValue, isLoading) {
if (isLoading || newValue === '') {
return;
}
alert(newValue);
var htmltext = '<div style="font-size:14px; line-height:1.5;"><p>Thank you for joining the <b>' + newValue + '</b>Employee Resource Group!</p><p>We\'re asking our members to provide us with information that will help us plan future events by location, your interests, and ability to support our volunteer initiatives. </p><p>This form will automatically capture your name and email address as it appears on Equitable\'s systems.</p > </div>';
alert(htmltext);
g_form.setValue('erg', htmltext);
}
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
46m ago
attached the screenshots
and no change on the form