- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2024 12:58 PM
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2024 01:17 PM
Hi @KS13 ,
Please try the autopopulate functionality in servicenow where u can just do this work without using a single code.
Autopopulate feature works from Utah version.
Please check this link for detailed steps
Thanks,
Danish
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2024 03:49 PM
you cant have cat.variable/field name having upper case letters in the "system" name.Also,not best idea using catalog client script when you can use "auto populate" -super easy to use and mega fast performance wise.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2024 01:17 PM
Hi @KS13 ,
Please try the autopopulate functionality in servicenow where u can just do this work without using a single code.
Autopopulate feature works from Utah version.
Please check this link for detailed steps
Thanks,
Danish
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2024 03:39 PM
agree fully here
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2024 01:22 PM
@KS13 : Please use the below code and replace variable names as necessary
function onChange(control, oldValue, newValue, isLoading) {
g_form.getReference('app_mne', doAlert); // doAlert is our callback function
}
function doAlert(app) { // reference is passed into callback as first arguments
if (app.getValue('Abc_can') ) {
g_form.setValue('LOB', app.getValue('Abc_can'));
}
}
Please mark this as correct answer and helpful if it resolved, or mark this helpful if this help you to reach towards solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-15-2024 02:03 PM
Unfortunately this did not work!