- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-03-2023 06:46 AM
Hi Everyone,
I have one requirement if the end user is updating the additional comments.
State of the form should change.
In my use case I have state:- 1: Analysis, 2: pending review, 3: Additional information required, 4: many more
> End user would be updating the additional comments when the state of the form would be "Additional information required"
> After the user will add the additional comments, state of the form should automatically change to "Pending Review".
Please help me to suggest the solution with code.
Solved! Go to Solution.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2023 02:54 AM
Hi Shiva,
Could you please try the below script in BR (on before)
if(current.comments.changes() && current.state = "Additional information required"){
current.setValue('state',"Pending Review");
}
It should work
Regards,
Imran
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2023 07:57 AM
What is your definition of an "end user"?
Blog: https://sys.properties | Telegram: https://t.me/sys_properties | LinkedIn: https://www.linkedin.com/in/slava-savitsky/

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2023 02:54 AM
Hi Shiva,
Could you please try the below script in BR (on before)
if(current.comments.changes() && current.state = "Additional information required"){
current.setValue('state',"Pending Review");
}
It should work
Regards,
Imran
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-05-2023 03:15 AM
Hi Imran,
Thanks it's working fine as expected.

- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-05-2023 04:30 AM
Glad to know it worked for you.
One thing if you remember while working on any scripting requirement is that - there could be multiple ways to script to reach a solution. Trying different approaches and picking the right one for your scenario is what that matters
Regards,
Imran
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
05-04-2023 07:57 AM
What is your definition of an "end user"?
Blog: https://sys.properties | Telegram: https://t.me/sys_properties | LinkedIn: https://www.linkedin.com/in/slava-savitsky/