what is a file system object in QTP

Answer Posted / smitha

correct code

const ForReading = 1, ForWriting = 2

Dim fso, MyFile

Set fso = CreateObject("Scripting.FileSystemObject")

Set MyFile = fso.OpenTextFile("D:\New
Folder\somefile.txt",ForWriting, True)

MyFile.WriteLine "Hello world!"

MyFile.WriteLine "The quick brown fox"

MyFile.Close

Set MyFile = fso.OpenTextFile("D:\New
Folder\somefile.txt",ForReading)

ReadLineTextFile = MyFile.ReadLine ' Returns "Hello world!"

MyFile.ReadLine

Is This Answer Correct ?    2 Yes 1 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain the difference between data driven testing and parameterization ?

593


Pls can anyone give me the entire code for the Keyword driven framework with respect to he Flight Reservation Window in detail with explanation. Pls explain in detail stepwise. Thanks a lot. Pls very urgent?.

1527


To which environments does quicktest professional supports?

550


Explain the difference between check point and output value?

502


What do you to script when objects are removed from application?

620






Can anyone help.i need total excelsheet operations,shortcuts in testing environment from starting onwards....

1438


What are the various types of Actions in UFT?

600


what type of automation is follwed in the project?

1493


how do i know how to use tools

1460


Give me At Least 5 Differences between DOCUMENTATION OBJECT MODEL(DOM)and COMPONENT OBJECT MODEL(COM)? Interviewer said me to WRITE the difference only in points not as you WRITE a paragraph ???? only in points

1637


What is the difference in the global and action sheet in qtp?

579


What is the difference between byref and byval in qtp?

593


When Recovery scenario actually starts while testing the application?

1554


Can U Explain about QTP tool from older version to latest version also its differences?

1525


what is the structure for the data driven framework

1493