What is the logic for reading(exporting)the data from flat
files to QTP?Can anyone explain me with an example?
I appreciate it!!!
Thanks!!!
Prasanna
Answer Posted / jhansi rani
the process is
assume the flat file is "abc.txt" which consists of some
data like sno and sname.
first we need to create object for that txt file like
set fso=createobject("scripting.filesystemobject")
next open that file using that fso
set f=fso.opentextfile("path of the txt file",mode)
1 --- readingmode
2 --- writing mode
8 --- append mode
while f.atendofline <> true
f.readline --- to read the line from the text file
.
.
.
.
.
perform require operations
wend
so total script is as follows
Set fso=createobject("scripting.filesystemobject")
Set f=fso.opentextfile("E:\testingexamples\abc.txt",1)
While f.atendofline <> true
msgbox f.readline
wend
| Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
please give me the code for doing retesting of gmail login page using functions so the function has to give the value
what is impact analysis on regression testing?
How to find a window is minimized or not
what are the critical test cases in crm? tell me atleast 5 critical test cases? what are the critical bug u find out while testing crm domain?
When I click on a link in web page.Link should open in new window.can anyone please let me know the script for this ---Koti
Which features or drawbacks of QTP lead to the upgrade for a newer version?
when a test case is written how u test using qtp
Hi all, I am using windows vista, I am in the process of learning QTP. When ever I try to work with insert mode in flight application , i am getting the error of 'Operation must use an update table query, fractional truncation(null) error. Can anyone help me regarding this?
I want to capture data(using keyword) from msdos application using QTP?... Below is little work i could do on it... /* Set app=CreateObject("Wscript.shell") SystemUtil.run ("C:\Users\Agent\Desktop\pumpsim\PUMPSIM.EXE") Window(“PUMPSIM.EXE”).Activate wait(3) app.sendkeys "N" */ Thanks in advance...!!!
after click on compose mail how can we attached a file in qtp with vbscript code
What is active screen?
Explain how to use QTP to check broken links on a page?
What is the Command used to start the QTP
What is the difference between the keyword view and expert view?
Explain the difference between data driven testing and parameterization ?