HOW CAN WE GET THE VALUE OF TEXT BOX IN QTP? can you give me
sample script for this where there is some condition. like
if "text" THEN msgbox() else endif
Answers were Sorted based on User's Feedback
Answer / shiva kumar dokka
if it is a windows based application, then it will be in
this way :
x= Window("Windowname").winedit("editboxname").Getvisibletext
msgbox x (or)
if it is webbased application then :
x =
Browser("Browsername").Page("Pagename").Webedit("Webeditboxname").GetROProperty("value")
msgbox x
Is This Answer Correct ? | 29 Yes | 8 No |
Answer / pooja
Using Object Spy find where u get the value for the
textbox, i.e in "text" property or "Value" property...
use "text" or "value" accordingly Getroproperty("text") or
Getroproperty("value")
If u want to chk whether the value in the text box
is "sunday" then....
a=Browser().page().frame().webedit().getroproperty("value")
if a=="sunday" then
msgbox ("displayed message is sunday")
else
msgbox ("msg is not sunday")
end if
Is This Answer Correct ? | 20 Yes | 8 No |
Answer / a.thirumalareddy@gmail.com
systemutil.Run "iexplore.exe", "newtours.demoaut.com"
getValue=Browser("Welcome: Mercury Tours").Page("Welcome: Mercury Tours").WebEdit("userName").GetROProperty("name")
msgbox getValue
If name<>userName Then
Browser("Welcome: Mercury Tours").Page("Welcome: Mercury Tours").WebEdit("userName").Set "thirumala"
Else
Reporter.ReportEvent micfail, "check edit box existancy", "Edit box is not existed"
End If
Is This Answer Correct ? | 9 Yes | 2 No |
Answer / sree
val=window("customer").edit("").GetTOProperty("text")
msgbox val
if (val=true) then
msgbox "pass"
else
msgbox "fail"
Is This Answer Correct ? | 10 Yes | 5 No |
a=inputbox("text")
msgbox a
if (a=true) then
msgbox "pass"
else
msgbox "fail"
Is This Answer Correct ? | 4 Yes | 11 No |
Answer / sdf
textProp=Browser("").Page().WebEdit().GetROProperties
("text")
If textProp<>"password" Then
msgbox "Enter Proper Password"
End If
Is This Answer Correct ? | 11 Yes | 19 No |
Answer / ramakrishna
x=inputbox("text")
mdgnox x
if (x=true) then
msgbox "pass"
else
msgbox "fail"
Is This Answer Correct ? | 7 Yes | 21 No |
Actually How do we use this Smart Identification Technology during Recording mode.
I want to execute 1st row of the local sheet and 3rd row of the global sheet parellely. write script to execute
how to tell about testing a website in interview using qtp?? what r the points to be covered mainly?
How can i find out any "text's" coordinates in excel sheet For example: I want to know the coordinates of "F" Column in the excell sheet While recording when i clicked on F column it is showing the coordinate values 385,9 but with out recording how can i find out them Suppose i want to clik on "H" column writing the script like this Window("Book1").WinObject("Book1").Click (...........) Here I Dont know what (x y )values should i enter Please any one can help me?
How to create configuration scripts
How smart identification works in qtp ?
Can launch two instances of qtp on the same machine?
Hai anyone please "Explain about Framework in QTP?"
i have doubt suppose iam purly working in manual, when i will get work to do on sql and performence testing? pls any one clarify doubt?
HOW TO FIND WEBTABLE? HOW TO RETRIVE THE WEBTABLE VALUES? PLZ TELL ME THE PROCEDURE.
How do we call Library Files(.vbs) in the Test Script Thanks in Advance...
Why do we use text checkpoint as we can make use of the same in the standard check point?