Hi Everybody,
Can anybody please tell me the how to display the result of
the QTP in the notepad text file rather than in the QTP
result window.
Suppose this is my simple script:WHich will open the
notepad file and enter some text and then will change the
font then will calculate how much time has been taken.Now,
in this script i want to display the result in notepad file.
Dim s
Dim starttimer,endtimer,timeit
s="uyetuywqtywqte"
SystemUtil.Run "notepad","","Y:\",""
Window("Notepad").WinEditor("Edit").Type micCtrlDwn + "s" +
micCtrlUp
Window("Notepad").Dialog("Save As").WinEdit("File
name:").Set "test1"
Window("Notepad").Dialog("Save As").WinEdit("File
name:").Type micReturn
Window("Notepad_3").Type s
Window("Notepad_3").WinEditor("Edit").Type micCtrlDwn + "s"
+ micCtrlUp
starttimer=timer
Window("Notepad_3").WinMenu("Menu").Select "Format;Font..."
Window("Notepad_3").Dialog("Font").WinEdit
("Font:").Type "cou" + micDwn
Window("Notepad_3").Dialog("Font").WinComboBox
("Font:").Select "Courier"
Window("Notepad_3").Dialog("Font").WinEdit
("Font:").Set "Courier"
Window("Notepad_3").Dialog("Font").WinEdit("Font:").Type
micReturn
endtimer=timer
timeit=endtimer-starttimer
print(timeit)
Please also tell me where the function for the text file
result will be declared and where it should be called.
Thanks,
Gaytri
Answer Posted / gaytri
Hi Chaitu,
Actually what I want to do is : I want to display the
result of my script in the notepad text file rather than in
the test result window, as it is usually displayed.here I
had given one example of my script. You can take any
example.
I think for this we have to create one function, but this
is not clear to me where to call that function and what
will be the definition of the function.
Please let me know if still it is not clear to you.
Thanks,
Gaytri
| Is This Answer Correct ? | 0 Yes | 1 No |
Post New Answer View All Answers
how can i pass a "cript"as a parameter in to a function
I want to know what are QTP functons and what are VB script functions. What is the difference between them.When we have to use these functions.
What are the different attribute used with regular expression?
What is exact meaning of Database Checkpoint in QTP 9.2 and what are the different types of the database check points?
How to associate shared object repository to test in qtp?
can u explain relative path architecture framework in qtp?
If u r using library files (Instead of Check Points) , How do u do bitmap check ?
How to check feasibility of the appliction?in automation testing?
Step 3&4 are repeated until an the object in recognised uniquely.
unique properties of button,edit box, radio button,check box?
What is standalone database?
What is meant by Step generator?what is the use of this? we have 3 steps know there what r all those.? can u all pls give me clear idea of this
How to execute a winrunner script in quicktest professional (qtp)?
How to create a standard checkpoint ?
Hi Friendss..., can any body help me.. 1. Tell me your achievements(Technically)..? 2. Tell me your strengths(Technically) and weakness(Technical)..? 3. Why are you looking for change..?