It identifies a global variable. Global variables retain a value local to the current user that is accessible from any any script and layout in your file.
Use a single dollar sign and you have a script variable. It presists only as long as the script that created it is executing and is not accessible from another script.
Thanks Phil. I found that about 10 minutes after I posted. I don't fully understand the situations in which you'd choose a local or global variable. Is the global used for unique identifiers such as a customer ID?
You'd use global values when you need a value to stick around while you perform other scripts and do other things where you'd use a script variable for a value that you only need while the script is being performed.
Here's a case where I use a global variable. Scripts that change layouts, open new windows, etc. can trip a lot of script triggers while doing so and these can slow down script execution and interfere with the results that I want. I use a global variable as a way to keep such scripts from being performed when I don't want them to.
I enclose each Trigger controlled script in this If block:
If [Not $$TriggersOff ]
Put rest of script here
Then, in a script that is going to change layouts, I do something like this:
Set Variable [$$TriggersOff ; Value: True ]
Go to Layout [
Set Variable [$$TriggersOff ; Value: False ]