08-20-2015, 06:50 PM
This is to validated the text filed is getting blank after clicking on the text field
Above code i have used.
Note:
On clicking the text box it will be blank and when we click the anywhere outside the text box then the pre-populated text has to displayed.
So when the UFT click the Text box we can observe the text field is getting blank and while UFT getting the RO Property the pre-populated text is getting displayed. Because of which my test cases is getting failed.
Code:
Dim valTXT
Browser(xx).Page(yy).webedit("userName").Click
valTXT = Browser(xx).Page(yy).webedit("userName").GetRoProperty("value")
if valTXT="" Then
print "The pasword field is blank after clicking"
else
print "The pasword field is not blank after clicking"
EndIF
Above code i have used.
Note:
On clicking the text box it will be blank and when we click the anywhere outside the text box then the pre-populated text has to displayed.
So when the UFT click the Text box we can observe the text field is getting blank and while UFT getting the RO Property the pre-populated text is getting displayed. Because of which my test cases is getting failed.