How to change incident's state to OnHold when the On hold reason is "Awaiting caller" ?

Student1
Tera Contributor

Hello all,

I have the following trouble:

When an agent changes the state of an incident to "On Hold" and sets the on hold reason as "Awaiting Caller", then the incident's state is saved as In Progress, as shown below. However, I want the state to be saved as "On hold".find_real_file.png

Any ideas and suggestions on how to make it work, are welcomed and much appreciated.

Thank you in advance.

1 ACCEPTED SOLUTION

asifnoor
Kilo Patron

You can write a onbefore update BR on incident table

Conditions

State changes to onhold

and reason is awaiting caller

Script

current.state=2;//put onhold value

Kindy mark the comment as a correct answer and helpful if it helps.

View solution in original post

3 REPLIES 3

asifnoor
Kilo Patron

You can write a onbefore update BR on incident table

Conditions

State changes to onhold

and reason is awaiting caller

Script

current.state=2;//put onhold value

Kindy mark the comment as a correct answer and helpful if it helps.

Ankur Bawiskar
Tera Patron
Tera Patron

Hi Student,

Please check the existing code which is performing this i.e. changing the On Hold to In Progress

You can make changes in the same script

OR

create before update BR on incident table

Condition: On hold Reason [IS] Awaiting Caller AND State [CHANGES TO] On Hold

Script:

current.state = '4'; // give here the choice value for On Hold

Regards
Ankur

Regards,
Ankur
Certified Technical Architect  ||  9x ServiceNow MVP  ||  ServiceNow Community Leader

Megha Padale
Giga Guru

Hi,

Found a similar thread, check this thread it will help you

https://community.servicenow.com/community?id=community_question&sys_id=c6384416dba7eb406c1c02d5ca96...

If my answer helped you in any way, mark answer as helpful and correct.

Thanks and regards,

Megha