Hi all! Have a question on variable declaration...I have 1 script, i split it into two actions, i declared a Public var in the first action but cant use it in the 2nd action? why is that so? Tnx in advance! :)

Showing Answers 1 - 5 of 5 Answers

Raj

  • Sep 26th, 2006
 

Even though you split your script into two actions. All actions are parts of that script. So actions are just to devide the script for your convience. But they are part of one script. I think this clears our question.

  Was this answer useful?  Yes

tina

  • Sep 26th, 2006
 

Hi raj! tnx for the reply...but my concern is why does my variable1 becomes empty when im on the second action..during action 1, i get value from data table and set it to variable1...but when i go to the 2nd action, im suppose to use the value in variable1 for condition cheking, but it becomes empty...i used 'public' to declare the variable. pls help...tnx! :)

  Was this answer useful?  Yes

suresh0249

  • Sep 28th, 2006
 

hai tina,you are telling that you have splited action into two parts right,you did'nt tell about in action repository you are running the script,if you are running in per action repository each action as its own object repository,if ur running in shared action repository there is only one object repository for that.my sugession is to go for properties of object repository checked to shared objet repository and try it.

  Was this answer useful?  Yes

srikanth

  • Nov 8th, 2006
 

hi,

i can give the simple solution to the above problem

capture the value of the varibale that you want to use  in the sction 2 in environment varaible and use it .

regards

Srikanth N.

  Was this answer useful?  Yes

Hi,

It's not a matter here in which object Rep. mode we r working with.Bcoz,..Even when we split an action into 2 parts (in per action mode),The obj. Rep. will b same for the splitted actions.But,When we do some modifications in any one action(after splitting),The modifications wil b concerned to that Object Repository only.Those modifications will not b reflected in the another action.

Now..coming to the variable in the 2 action....If u face the problem,Just export that value of the variable at the end of the first action & pass the value of Variable to the 2 action..

If anything went wrong..pls let me know.

klrao.kanithi@gmail.com

  Was this answer useful?  Yes

Give your answer:

If you think the above answer is not correct, Please select a reason and add your answer below.

 

Related Answered Questions

 

Related Open Questions