Title
Multiple File Variable Passing
Post
I know how to get scripts in one file to fire in a sepearate file however, I was wondering if there was anyway to pass variables from file to file? Perhaps I had a value that I wanted to transfer during the script in order for it to finish. Thanks for the help.
If you want the values as variables in the script where they are passed when you send a list of values, use a series of set variable steps at the start of your script to extract the individual values from the parameter list and place them in variables.
If you paramater list has three values, here's one way to set it up:
Set Variable [$Variable1 ; value: GetValue ( Get ( Scriptparameter ) ; 1 ) ]
Set Variable [$Variable2 ; value: GetValue ( Get ( Scriptparameter ) ; 2 ) ]
Set Variable [$Variable2 ; value: GetValue ( Get ( Scriptparameter ) ; 3 ) ]
Now you've converted your parameter list into individual variables. This, when placed at the top of your script also help document the structure of your parameter list--which can make understanding your script easier when you work with it at a later date.