Help with a script

Community Alums
Not applicable
 
 
3 REPLIES 3

Moin Kazi
Kilo Sage
Kilo Sage

Hi @Community Alums ,

 

In the code below, you are multiplying by 10, but since you are already storing the days in the _days variable, I don’t think it’s necessary to multiply by 10 afterward.

You can remove the 10 from the code and put like that code below.

 

_dur = new GlideDuration(60*60*1000*_days);

 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

If you found my response **helpful**, I’d appreciate it if you could take a moment to select **"Accept as Solution"** and **"Helpful"** Your support not only benefits me but also enriches the community.

 

Thank you!
Moin Kazi

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Community Alums
Not applicable

That doesn't work. it updates the due date with following day so adds 1 day instead of 8 or 10 days

mihirlimje867
Tera Guru

Hello @Community Alums ,

We need to debug this code you can do a thing that you should add the gs.info() message line by line and then check the logs then you can identify where the exact problem is.
Additionally, you can check your declared variable as return a which value or check if is it correct or not using gs.info().



Please hit on the helpful button.
Thank you.