Posted: Wed Apr 07, 2004 1:33 pm Post subject: declaring a Global Variable
Novice
Joined: 28 Aug 2003 Posts: 18
I want to declare a global Variable in one of my compute Nodes and then use that global variable in another compute Node. This is what I have done, but it doesnt work:
Compute Node 1:
(This is the only Code that Ihave in the first Node)
SET OutputRoot = InputRoot;
SET OutputLocalEnvironment.Variables.Email = 'someEmailAddress'
Compute Node 2:
CREATE FIRSTCHILD OF OutputRoot.XML.Message Domain('XML') NAME 'To' VALUE Email;
The Variable Email is always blank. What am I doing wrong? How do I fix this?
Thanks
Use Environment instead of OutputLocalEnvironment.
Or make sure to change the mode of your Compute Node to pass "LocalEnvironment and Message", instead of the default of "Message".
And you also need to refer to your field as 'InputLocalEnvironment.Variables.Email", not "Email" in your later compute node. _________________ I am *not* the model of the modern major general.
Posted: Wed Apr 07, 2004 2:04 pm Post subject: global variable
Novice
Joined: 28 Aug 2003 Posts: 18
I changed it to Environment.Variables.Email and chaged the Compute Mode to LocalEnvironment and Message. Also made the change at the latter Compute node to :
CREATE FIRSTCHILD OF OutputRoot.XML.Message Domain('XML') NAME 'To' VALUE InputLocalEnvironment.Variables.Email;
It still fails. What should the compute Mode be for the second Compute Node.
Thanks for the response.
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