How can I pass values from one action to another in QTP ?

Answer Posted / riju

Define a parameter variable in the action(eg: Action2) to
which the value is to be passed into.(that can be done by
right cliking on that particular action --> Action -->
Action Properties --> Parameter(tab) --> '+' button on input
parameters and give the parameter name(eg: i)

and in the code, ie. in Action1

i = 10
RunAction "Action2", oneIteration,i

and in Action2

b = Parameter("i")
msgbox b

Is This Answer Correct ?    19 Yes 3 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What if recovery scenarios is also failed for identify the alert ? (We are handling unexpected popup through recovery scenarios but if still recovery scenarios also failed than what should be the approach)

1005


If I change the object name in one action will it be updated in all the actions? Or not?

590


What is the extension of the qtp local repository?

557


How is the Bitmap checkpoint different from Image checkpoint?

619


What is the default object synchronization timeout in qtp?

634






Does quicktest professional (qtp) is unicode compatible?

534


Hi can anybody send me the QTP material, To my email ID: nuve1284@gmail.com ?

1679


Will down time for server and content maintenance/upgrades be allowed? how much?

609


What is the synchronization point in qtp?

557


While spliting an action in QTP 10.0 getting an error : "This Line is a part of Script Block.You cannot split the action on this line." how to re-solve this and split the script into actions?

1415


How to run an integrated test scenario using Multiple Actions? How to use the QTP Step Generator?

3435


I want to test my vb.net solution file using qtp. Does Qtp test only .exe file?

1717


Hello Everyone, Please provide me the practical example of business component concept of QTP.Like how to create business component,how to connect the quality center etc.... Thanks in advance, Gaytri

1397


Tell some commonly used Excel VBA functions?

587


in qtp if we record a object and we record the object using virtual wizard then by which way the object is recognized that means recorded

1514