How can you Open a Notepad and How can you write the test
Resuts in Notepad by Using QTP?

Answers were Sorted based on User's Feedback



How can you Open a Notepad and How can you write the test Resuts in Notepad by Using QTP?..

Answer / sushma

Result = "The test is passed"
Set a=createobject("Scripting.filesystemobject")
Set b=a.opentextfile("E:\raju\1.txt",2)
b.writeLine Result
b.close
Set a = Nothing
Set b = Nothing

Is This Answer Correct ?    7 Yes 2 No

How can you Open a Notepad and How can you write the test Resuts in Notepad by Using QTP?..

Answer / kavitha

dim fso,f,x,y

Set fso=createobject("Scripting.filesystemobject")
Set f=fso.opentextfile("path of the file",1/2/8) {1-reading
mode, 2-writing mode, 8- read and write mode }
While f.atendofline<>true
x=f.readline 'it reads the value

In notepad file u have to put the data and attached to this
program to run the file morethan one time.

Is This Answer Correct ?    3 Yes 1 No

How can you Open a Notepad and How can you write the test Resuts in Notepad by Using QTP?..

Answer / king

Set a=createobject("Scripting.filesystemobject")
Set b=a.opentextfile("E:\raju\1.txt",2) {1-reading mode, 2-
writing mode, 8- appending mode }
While b.atendofline<>true
y=b.readline ---- Read the line on particular
mentioned fine

b.writeline "I Love QTP" --- write the line on particular
mentioned file

Wend


i think it's working proerly, if u have any quarries plz
let me know
raju.gudla@gmail.com
9823257761

Is This Answer Correct ?    3 Yes 2 No

Post New Answer

More QTP Interview Questions

how to identify the user defind varibles? plz tell me

1 Answers  


How to test login module with different username and password by using data driven testing in QTP?

0 Answers   HCL,


how to evalute defects in QTP script?

0 Answers  


How to database testing by manualy?in my db having 100 records when i am retriving the data from db it shows in frent end 30 records how to find bug using QTP?plz Exp realtimers (Chandana)

7 Answers   Wipro,


how can we know the program is testing by multiple test data in data driven frame work?

1 Answers   CTS,






if you have the same application screen with 7 drop down boxes and approximately 70 values how do you test with QTP?

2 Answers   Ordain Solutions,


Hi Suppose u have complex Test scripts which u vl write first and which u vl execute first

2 Answers   Symphony,


we have 10 actions in out test how can we convert 9th action is main action ? how ?

5 Answers  


When I parameterize a script then for each iteration script is executed from begining to end. If I want to execute some middle steps multiple times using Parameterization (avoiding begining and end steps), what is the solution of this (e.g. total steps are 1 2 3 4 5 and i want 2 3 4 only(not 1 nd 5)

2 Answers  


What is the regular expression for Yahoo mail Inbox?

2 Answers  


with out using import sheet came is it possible to get the excel sheet ?

2 Answers   Ordain Solutions,


How can we disable popup blocker?

1 Answers  


Categories