How do auto populate requested field on Project form
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-11-2022 11:25 AM
I am a sys admin and not familiar with the whole development/config in ServiceNow
I do, however, want to auto-populate a Requested by field on the Project form so that whenever I open up the project form it auto-populates with the logged-in user
I would like for it to auto-populate with the logged-in user just like the change request form
On the change form, when you open it to create a change request, it auto-populates the requested by the user.
I have tried looking at OOTB to see if I can see the configuration but I am not able to identify it
Thank you
I am sure if I am able to identify the code, I should be able to get it done.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-11-2022 01:40 PM
That was a good question. Please remove the script and revert the changes to old script by checking use dynamic default and save it .
For this autopopulation you can
write an onload client script
1) open thr form and right click on the banner
2)click on configure and then click on the client scripts
3) create a new one selecting the type
as onload and write below script
g_form.SetValue('your field backend name', g_user.UserID);
Please mark the answer correctly if it helped you
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-11-2022 11:39 AM