How do we pass values between actions in one test other than by action call?

Say for eg, if action_1 contains a variable 'C' containing the value of a+b, how can we display the result (value of 'C') in action_2 ?

Showing Answers 1 - 6 of 6 Answers

gilshalev

  • Mar 5th, 2008
 

Hi
You can assign the value to an Envirnoment collection:
Envirnoment("C") = c

This collection is familiar in all actions.

  Was this answer useful?  Yes

ManjuPillae

  • Mar 26th, 2008
 

We can Pass values between actions by storing values in DataTable or by storing the values in Environment Variable.

And we can refer in other Action.

  Was this answer useful?  Yes

Go to expert view of Action2 and write the following code.

RunAction Action1 oneIterartion a,b,c
msgbox c

Here variable store the final value(a+b) returned from Action1.

Now declare the following line in Action1

x=Parameter(in_01)
y=Parameter(in_02)
Parameter(out_01)=x+y

where in_01,in_02 are declared as the Input Parameter for Action1 and out_01 is declared as the Output Parameter for Action1

  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