Basic question about variables

Sir @JMichaelTX @Tom, dumb question about variables:

Why does Pause accept variable names without the percentages, and why using %Variable%Pause_Min% won't work?

also, why does this macro work without the %Variable% part?

Because the Pause data field is a NUMERIC field, not a TOKEN field.
The expression %Variable%Pause_Min% is a token for a Variable.

In general, all Global Variables should use the full token of "%Variable%YourVariableName%".
Local and Instance Variables may drop the "%Variable", because their required prefix always identifies them as a Variable.

Sometimes a Global Variable can get away without the "%Variable", but it is NOT recommended, and can fail under some circumstances.

3 Likes

thanks for the prompt reply,
Read the wiki section about tokens, but still don't get it...

Roughly spoken:

You have at least three different kinds of “fields”:

  • “normal” text fields
  • numeric fields (calculation fields)
  • dedicated variable fields

In normal text fields you have to insert the variable in its token form:

Screen Shot 2020-03-06 at 10.14.14-pty-fs8

With the other types you don’t need the token form:

Dedicated variable field:

Screen Shot 2020-03-06 at 10.13.35-pty-fs8

Numeric (calculation) field:

Screen Shot 2020-03-06 at 10.20.40-pty-fs8

Screen Shot 2020-03-06 at 10.12.24-pty-fs8

3 Likes

Thanks, great answer, should be stickied to the top!!

And now I finally get what that damn C means
image