Wait for condition script in workflow

Bindhu1
Tera Contributor

Hi team,

I have a requirement, where I have to wait for X number of days in the workflow before creating a task, this X days days is taken from a variable of RITM that is single line text, can someone help me with the script.

 

Bindhu1_0-1695725172974.png

The workflow has to wait for the above number of days before the task is created.

 

Thanks in advance.

1 ACCEPTED SOLUTION

palanikumar
Mega Sage

In workflow use "Timer" activity. Do the following

1) Set "Timer base on" to Script

2) Use the below code in script

answer = parseInt(current.variables.<var>.toString()) * 24 * 60 * 60;

Thank you,
Palani

View solution in original post

1 REPLY 1

palanikumar
Mega Sage

In workflow use "Timer" activity. Do the following

1) Set "Timer base on" to Script

2) Use the below code in script

answer = parseInt(current.variables.<var>.toString()) * 24 * 60 * 60;

Thank you,
Palani