How do you done Data-Driven Testing using MS-Word. What is
the script for that

Answer Posted / rajani

option explicit
dim fso,f,n
set fso=createobject("Scripting.filesystemobject")
set f=fso.opentextfile("path of the word document",1,false)

while(f.atendoflen<>true)'reading the word doc.
n=f.readline 'retrive the data from doc.line by line
wend.

Is This Answer Correct ?    3 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

When you open QTP, how many sheets you can see?

641


1.How to record ,capture and also script to capture the close buttons. 2.How to record ,capture and also script to capture the options ---File ->save and File ->close in a browser and PDF files. 3.How to compare the Excel sheet values in a report using QTP scripting. 4.How to compare 2 PDf reports using QTP scripts as well reording. 5.How to compare 2 Excel reports using QTP scripts as well reording. 6.How to save a PDF report to a folder and then translate the report to an Excel type of report and compare that Excel Report with an other excel report. Please clarify me

1589


give me the code to save all messages of inbox of gmail into a folder and notepad

1609


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?

1387


What is method name to compare two XML files.

1528






What are the different types of recording modes in qtp? Which will be used when?

550


What are parameterizing tests?

541


Suppose I have three hyperlinks with same properties. How to solve this and what are the ways to solve this. we can solve this by using index property but what are the other ways we have have to solve this problem. Login (href: btnlogin.aspx) Login (href: Sourcelogin.aspx) Login (href: homelogin.aspx)

1541


On what document base Descriptive programming is written if build is not yet ready ?

869


How should I click on the right click menu objects When I trying to add the object properties to the OR.It is showing only Window(Window).Not all the objects of the window. Also while recording I found No script. How to solve this>.

1529


How does qtp identify gui object?

580


we add library file used in test via settings or through "ExecuteFile" command. when we implement framework do we make common library file and load the same for all the test cases execution?

1569


How many scripts did you have?

1689


I hav installed QTP8.2, im working on webapplication, while running the script giving error msg like "QTPro.exe generated errors and will be closed by windows. You will restart the program. An error log is being created". Pls anybody what is the problem, what i have to do for this? Thanks...

1708


How to do the scripting. Is there any inbuilt functions in qtp as in qtp-s.

516