how do pass parameters from one action to another action

Answer Posted / aarati borse

Whatever Ravi has mentioned it is true...
Practically we can do like this..
Here I am using Action Parameters...
REquirement in Flight Reservation Apps is

Name by which user is getting logged in by same name a new
order also should get inserted..

1)Record for login window.
2)Rename the action as login_name
3)Pass the op value in action parameters as "agent_name"
4)By using Getro property fetch the agent name value and
store it in parameter agent name itself.
code willbe
parameter("agent_name")=window("FR").........winedit("Agent
Name").getroproperty"text"
5)save the test.


6)Now record for the insert order in new test
and make changes as follow

Window("FR").winedit("Name").set parameter("agent_name")
7)Make this action reuasable and rename it as insert_name
8)Save all changes in the test.
9)Move to first test again that is in login_name action
10)Keep ur cursor at end and call the existing action i.e
insert_name.
11)In expert view u will get the statement as
RunAction "insert_agent",oneIteration
we need to add as
RunAction "insert_agent",oneIteration ,parameter
("agent_name")
12)save d changes again..

13)now run login_name action

It will work...

Is This Answer Correct ?    1 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How to recognise the webelement and verifying that webelement is enabled?

1733


Can we run test with out adding object in object repository? How it is possible?

659


How qtp recognizes the object?

765


Hi How to retrieve data from web element line by line?

1658


How to use conditional loops in qtp ?

681






What is expert view and keyword view?

712


Why do we use "Text checkpoint" If we can make use of it in "standard checkpoint" ?

1565


How do you open adobe acrobat file in QTP and do some testing on that file ?

715


What do you mean by iteration?

734


Want to verify notepad reports using QTP framework or any other BV script method. Can anyone share the method to achieve it? Eg. Person Name is the header and the actual name is John then how can we verify weather person name is John

2247


PLEASE TELL ME WHEN DO YOU USE THE OBJECT SPY AT RUN TIME

6266


If an application name changes frequently i.e while recording it has the name, in this case, how do qtp handles?

677


I want to know what are QTP functons and what are VB script functions. What is the difference between them.When we have to use these functions.

1374


Explain how you can find length of array in qtp?

669


Did QTP prove efficient for your project? Yes or No, explain?

6222