g_form.setvalue isnt working for lookup selectbox in portal
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-13-2024 02:33 AM
I have a client script that run on "UI Type = All" and I'm setting values for multiple fields. All of them are working as expected except a lookup select box [Doesn't work only in portal]
7 REPLIES 7
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-13-2024 02:43 AM
Can you show a screenshot of the script.
-Anurag
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-13-2024 02:45 AM - edited 03-15-2024 11:23 AM
var url2 = top.location.href;
var cv_state = new URLSearchParams(url2).get("state");
g_form.setValue('environment', cv_state .toString());
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-13-2024 02:50 AM
Wonder of this is the issue https://support.servicenow.com/kb?id=kb_article_view&sysparm_article=KB0725048
-Anurag