i have to pass the testcases into userid anf password of
gmail login page using functions you can take your own
testcaseslike
userdid should take only lowerletters it should not take
special charactors and uppercase letters and password should
take only numericvalues it should not take alphanumeric and
alphabets
Answer Posted / m.hemakumar
Login_Info "asaddd","1531565"
Public Function Login_Info(UserId,PassWord)
Browser("title:=.*").Page(("title:=.*").WebEdit
(oEdtUserid).Set UserId
Browser("title:=.*").Page(("title:=.*").WebEdit
(oEdtPassWord).Set PassWord
End Function
Note: 1)where oEdtUserid and oEdtPassWord are descriptive
objects
2)Login_Info "asaddd","1531565"
when function is not returning any value
3)Login_Info ("asaddd","1531565")
when function is returning value
Ex:
Val=Login_Info ("asaddd","1531565")
Public Function Login_Info(UserId,PassWord)
Browser("title:=.*").Page(("title:=.*").WebEdit
(oEdtUserid).Set UserId
Browser("title:=.*").Page(("title:=.*").WebEdit
(oEdtPassWord).Set PassWord
Login_Info=1
End Function
Val Variable contains 1
| Is This Answer Correct ? | 2 Yes | 0 No |
Post New Answer View All Answers
Both static and dynamic arrays are handled by the vb script. Is it true?
How do Parameterization and Data-Driving relate to each other in QTP?
Explain the difference between data driven testing and parameterization ?
Where can I find and view run-time data table?
How to handle the exceptions using the recovery scenario manager in qtp?
How to test fly out menu in qtp?
How you debug your script?
What are the trigger events in qtp?
Sql questions to find second max salary and how to use joins
what is defenetion of kiran can u tell me plz CVS, SVN
how to download mercury qtp9.2 ny internet ?
What is contained in the object repository?
What is Curd testing?
What is keyword driven framework?
how to disable the pop ups through QTP using a script