Comparing two date values in Action Script

I need to compare two date values in an action script line, but I’m having syntax issues and I just can’t see where my error is:

What I really want to do is assign a date value to a parameter:

parameter “ManualWindowEndDate” = “{(now) + (3*day)}”

** This works perfectly - no issues **

However, when I try to compare that to the value of “now” I get an error. I thought the error was in the way I’m parsing the parameter’s value, but then I tried this and got essentially the same thing:

pause while “{(now)} = {(now)}”

The error is “an unknown error occurred” and the output is:

Pausing While “{(now)} = {(now)}” (Evaluated: Thu, 15 Dec 2016 12:11:00 -0500 = Thu, 15 Dec 2016 12:11:00 -0500").

Evaluation Failed! Error encountered.

So since both “now” are evaluating correctly and they are identical in value, this line should technically stop the debugger until I stop the execution. So what am I missing in my syntax here?


You want to compare the two strings in the relevance statement, instead of creating two relevance statements and trying to compare the outputs (pause while doesn’t do any evaluation, you need to do it in relevance):

pause while {now = now}

I think you are looking for something like:

pause while {now < parameter "ManualWindowEndDate" as time}