Forum Discussion

jbcmt's avatar
jbcmt
Occasional Contributor
13 years ago

Global vs Project variables

Are there any advantages to using Project Variables vs  Global Variables?  Right now, I have all my globals defined in a unit which is included in my test scripts.  Any reason to switch and use project variables instead?

1 Reply

  • Hi,



    Scripting and project variables are different variable types, and they behave differently. In general, it's up to you to choose which are more convenient in your case.



    As for advantages, as an example, project variables can save their values between test runs, and you can assign different values for different people which access your project via network (this may be needed, for example, to store machine-specific paths). Also, project variables are available everywhere in your project, and you don't need to include units into each other to access them.