g_form.getOption() doesn't work in Workspace - need an alterative
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-29-2024 03:53 PM
Hello everyone. My current project has a requirement - when Category is set to a certain value, it adds an extra option to the Subcategory choices. To do this, I created a UI Policy with scripts like these:
Execute if true:
Execute if false:
This worked fine at first, but we later discovered that it didn't work when testing in the Workspace. After looking it up, I discovered that g_form.getOption() doesn't work in Workspace. Are there any alternatives I can use? I was using getOption() specifically to check to see if the extra Subcategory choice already existed.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-30-2024 10:07 PM
Hi @Marc D
It is not working in Agent Workspace or in Workspace view ? I tried simulating it on my PDI and I am able to make getOption work in the Workspace view but not in Agent workspace.
Thanks & Regards
Amit Verma
Please mark this response as correct and helpful if it assisted you with your question.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
01-31-2024 07:24 AM
It is not working in Configurable Workspace. Workspace view in classic UI works fine.
In any case, my team decided to instead use dependent values so that this issue won't hurt the project.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
10-23-2024 12:08 AM - edited 10-23-2024 12:10 AM
Hi
I had the similar situation, I have used getOption in onChange client script to store the oldValue in other field. The script worked fine in Native UI but didn't work in Workspace, after a lot of research I found a alternative solution for this. Used display BR to get internal values
Native UI script