 |
SoftTree Technologies
Technical Support Forums
|
|
Author |
Message |
mpadilla
Joined: 02 Jul 2008 Posts: 33
|
|
Global variables not working on "run" mode |
|
Hi
I am trying to set a group of global variables to use across multiple jobs. I am using 24x7 for Windows v.3.5.3g The job to declare and set initial values for the variables is schedule to run on 24x7 start. This job runs on start (at least that is what shows the trace screen).
When I try using the global variables in a different script, when I test the job using the debug option, the variables get assigned and the job works ok. When I schedule the job to run on schedule or if I run it directly with the "run" option, I get an error message saying "Undefined Variable"
Here is the code I use for initializing the global variables:
------------
dim global.var1, string
dim global.var2, string
dim global.var3, string
set global.var1, "global.var1"
set global.var2, "global.var2"
set global.var3, "global.var3"
-------------
The job I created to test the variables is:
-----------
dim command, string
dim command2, string
messagebox(global.var1)
concatex (global.var1," is the variable 1 ",global.var2, "is the variable 2", command)
messagebox(command)
concatex (global.var2,"is the variable 2 ",global.var3, "is the variable 3", command2)
messagebox(command2)
---------------
This is the error in the log:
5/27/2009 10:58:58.875 0 473 0 Test Global Variables Job started.
5/27/2009 10:58:58.921 2 473 0 Test Global Variables An error occurred while executing automation script: Line 3: Undefined variable.
5/27/2009 10:58:58.953 2 473 0 Test Global Variables Process finished with exit code 1
5/27/2009 10:58:59.093 1 473 0 Test Global Variables Job has been disabled!
---------
|
|
Wed May 27, 2009 11:01 am |
|
 |
mpadilla
Joined: 02 Jul 2008 Posts: 33
|
|
|
|
Here is a screen shot of the job trying to use the global variables, when run in debug mode:

|
|
Wed May 27, 2009 11:05 am |
|
 |
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7949
|
|
|
|
My guess is that your jobs are set to run detached. As a result, they don't have access to the shared memory and cannot read global variables updated by other jobs.
Detached mode protects the scheduler from job resource leaks and crashes, but prevents jobs from sharing memory. If you need jobs to share global variables and you think the jobs are trustworthy, please set them to run non-detached.
Note that version 3.6 is going to support sharing of global variables in detached jobs. We are expecting this version to be available next month.
|
|
Wed May 27, 2009 11:09 am |
|
 |
mpadilla
Joined: 02 Jul 2008 Posts: 33
|
|
|
|
You mentioned version 3.6 would be available this month. Do you have a date for the release yet?
Thanks
|
|
Wed Jun 17, 2009 9:22 am |
|
 |
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7949
|
|
|
|
We are targeting last week of this month.
Regards
|
|
Wed Jun 17, 2009 9:34 am |
|
 |
mpadilla
Joined: 02 Jul 2008 Posts: 33
|
|
|
|
Any news on a possible date for the new release?
|
|
Mon Jul 13, 2009 11:29 am |
|
 |
SysOp
Site Admin
Joined: 26 Nov 2006 Posts: 7949
|
|
|
|
Today. It is actually being published now. Various documents and links will be updated on our sites through the day. Stay tuned :)
|
|
Mon Jul 13, 2009 11:43 am |
|
 |
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|
|