How do u insert an object during runtime in qtp?
Answers were Sorted based on User's Feedback
Answer / ravi
Where do you want to insert object ??
We can create object at runtime using createobject()
function in VBScript.
For ex:
Set con = createobject("ADODB.Connection")
The above statement creates connection object at runtime.
| Is This Answer Correct ? | 3 Yes | 1 No |
Answer / baji prasad ch
By Using the Flat files Parameterization we can insert
objects during runtime.
[Parameterization is the process of supplying multiple test
data. That means sometimes we are executing our test
scripts with multiple test data We can parameterize our
Test Scripts in different ways.]
VB script to retrieve values from flat files during runtime:
Set A=createobject("Scripting.filesystemobject")
Set B=A.opentextfile("C:\Documents and
Settings\baji.prasad\Desktop\baji.txt", "1",true)
While B.atendofline<>true
X=B.readline
Dialog("Gracenote® MusicID (CD)").Activate
Dialog("Gracenote® MusicID (CD)").Activate
Dialog("Gracenote® MusicID (CD)").WinEdit("TOC").Set X
Dialog("Gracenote® MusicID (CD)").WinButton("Lookup
TOC").Click
Dialog("Gracenote® MusicID (CD)").WinButton("Rip CD Tracks
and Add").Click
Wend
| Is This Answer Correct ? | 0 Yes | 1 No |
How to capture screenshots of Exceptions/Errors during run- time?
How can we get a textcheckpoint in QTP9.1?
how can we handle exceptional handling in qtp
Could anyone help me for the below scenario: i am using the descriptive programming for my account, in which we have to generate the contract in the MS-word. when i generate this doc, we need to click on enable macros to continue further. but i am unable to make qtp to click on this. if anybody faced the problem like this??? pls help to get it resolved? Thanks in advance
Can you write a script for to insert array elements in an excel A to Z columns only. if the number oe elements in the array is greater than the number of columns (A to Z), come to next row and proceed furthur. eah cell should contain only one array value.
how to identify the user defind varibles? plz tell me
suppose i give valid user id and password to open an web base application on qtp.how qtp will know itis a valid user id and password
how to identify a webtable coulmn values ,if we spy the coulmn value it is sometimes identifying as Webedit and some times it is identifying as "webelement", Could any body let me know how to handle the issue?
is it possible to change the date format like MM/DD/YY into DD/MM?YY through script in QTP
somebody please say me why we go for using regular expressions,actions.what is the main and exact use of this in real time applications.real time testers pls answer my question with example if u can
need clear explanation of actions and functions in qtp with examples?can anyone suggest me gud site for that other than qtp manual?
assume i have few url link how will i dynamically call then using descriptive programming?