Page 1 of 1

Variable changed after set

Posted: Wed Apr 07, 2021 7:59 am
by ivan.ulens@vcst.be
Set Variable Bijlagenaam
{Bijlagenaam1}_D{Year}{MonthNo}{Day}_T{Hours}{Minutes}{Seconds}.pdf
Wait For File
{Pathnaam}\{Bijlagenaam}
Script error: E: 7/04/2021 7:49:52: File "D:\TRANSFERZONE\TEMPBARTENDER\VCST_DELIVERY_D20210407_T074952.pdf" doesn't exist.
The File "D:\TRANSFERZONE\TEMPBARTENDER\VCST_DELIVERY_D20210407_T074951.pdf" exist.
What can cause this?

Re: Variable changed after set

Posted: Wed Apr 07, 2021 8:32 am
by Oleg
When you set a variable be sure to turn on "Expand variables" option
Image
In this case RoboTask expands all variables and then set the value to variable

If this option is OFF then RoboTask assigns the value as-it-is. In this case RoboTask expands nested variables when you use the variable in other actions
You are using variables that depend on the current time. Thus, the value depends on the time of use.

Both modes can be useful for different cases

Re: Variable changed after set

Posted: Wed Apr 07, 2021 1:21 pm
by ivan.ulens@vcst.be
Thanks, now it works.