How we can add actions in the test using QTP?

Answers were Sorted based on User's Feedback



How we can add actions in the test using QTP?..

Answer / sowmya

Your question was how to add actions in the test.
Are you trying to add a new action in the test itself or are
you trying to call an existing action?

1.If you are trying to add a new action: Alt I then N
or go to insert and select new action. It will generated
Action 2

2.Again the same procedure go to insert and you can select
Call to Copy of an Action or an Existing Action

Is This Answer Correct ?    5 Yes 0 No

How we can add actions in the test using QTP?..

Answer / sreeprasad

There are four actions call to action ,copy of action,call

to exesitng action,call to winner,split action just right

click on any one select it

Is This Answer Correct ?    2 Yes 0 No

How we can add actions in the test using QTP?..

Answer / sandeep

Please refer to this VB Script.

You can add new action programmatically also.

' Dim qtApp, ActionContent, ActionName, ActionDescr,
NewAction, SecondAction, script
Set qtApp = CreateObject("QuickTest.Application") ' Create
the application object
qtApp.Launch
qtApp.Visible = True
qtApp.New

ActionContent = "Window(""Calculator"").WinButton
(""1"").Click" & vbCrLf & "Window(""Calculator"").WinButton
(""+"").Click" & vbCrLf & "Window(""Calculator"").WinButton
(""+"").Click" & vbCrLf & "Window(""Calculator"").WinButton
(""="").Click"
ActionDescr = "A new sample action for the test."
ActionName = "Action" + CStr(qtApp.Test.Actions.Count + 1)

'Add a new action at the begining of the test

Set NewAction = qtApp.Test.AddNewAction(ActionName,
ActionDescr, ActionContent, False, qtAtBegining)



For Attributed like ActionContent, please read all text
from any Text file in which you have already written some
code.


With this help you can generate new QTP Script pretty
quickly.

Is This Answer Correct ?    1 Yes 0 No

How we can add actions in the test using QTP?..

Answer / thangaraj

Set NewAction = qtApp.Test.AddNewAction(ActionName,
ActionDescr, ActionContent, False, qtAtBegining)

Is not working. Please let me know the exact code for
creating a new action. Thanks in advance

Is This Answer Correct ?    1 Yes 0 No

How we can add actions in the test using QTP?..

Answer / rafi

just right click on the test pane select action if you want
give action name

Is This Answer Correct ?    0 Yes 1 No

Post New Answer

More QTP Interview Questions

Which functionalities of QTP used in banking project?

0 Answers  


What are the details steps to connect a remote mysql database in QTP

1 Answers   Verizon,


We are using the QTP version 9.0 where we want to call objects from global repository for a particular function at runtime for increasing the performance of framework.We are actually looking for loading the objects under test (OAT) dynamically when script runs and would like to unload the same once the execution of the script is completed.

2 Answers  


What are software testing metrics

3 Answers  


how you have used object libraries? plzzzzz do answer

1 Answers  






What is the use of text output value in quicktest professional?

0 Answers  


Where virtual objects stores results?

4 Answers  


Hi i want to export the data from applicatioon to excel and later i want to import and use it for my scripts hoe can i do this?

1 Answers  


before launching qtp, we need to close all the open browsers u dont know what are all the browsers either it might be ie,mozilla etc and u dont know how many brosers are open.... u need to close all these before launching qtp.. can anyone plz temme d solution...

2 Answers   Keane India Ltd,


How can I use Call dlls in QTP ?

0 Answers  


How to add a standard checkpoint in your test ?

1 Answers  


Which object model ur used in ur project

2 Answers   Cap Gemini,


Categories