Answer Posted / 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 |
Post New Answer View All Answers
Describe function procedure in vbscript.
What are the challenges u faced in testing with crm domain? How u overcome with?
Write a script to customize the test results in PDF and HTML format.
What is the difference between a Function and Action in QTP?
What is a programmatic description?
how can i pass a "automation script" as a parameter in a function give me need full suggestion thank inadvance
Tell me about your project? please help me how to tell about insurance project
What is accessibility check point?
Hi all can any one give me roles and responsibilities for QTP (not WINRUNNER)
How you are developing the script? Using record and play back or manual?
What is reusable action?
explain keyword driven framework with banking domain?
What is the script for database check point, bitmapchek point, regular expression ?
Can any one tell me.......How the test engg's start testing in the compy environment.....real time tester PLSSSS help me i need in depth information regarding this...
How many types of parameters are available in quicktest professional (qtp)?