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
Answers were Sorted based on User's Feedback
Answer / 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 |
Answer / shavali
hear i cant understand val function can u please explain 3
function from val_info on wareds when the function is
retuning a value
| Is This Answer Correct ? | 1 Yes | 0 No |
The xls contain data. how to get number of columns form the sheet?
i am trying to capture the URL from the open browser and store it. pls give me solution how we can do this in QTP. thanks
After running scripts how you report results ,there is any specific report form
i have data in excel sheet.i imported the data in data table.while doing parameterization,how the code knows it is a valid or invalid data?
how to add run-time parameter to a datasheet?
1 Answers Mphasis, Ordain Solutions,
I have developed and executed a script successfully, and saved the same to QC. When I tried to execute the script from QC, the script is not executing. What are the possible reasons?”
i have two questions for regular expression :- Q1. I have date pattern eg-29/11/2011 29-11-2011 29.11.2011 Que- if any separator is there between date,month and year pattern should match else it should not match eg- pattern should not match in case of 2911-2011 Q2. let say i have a string and there is a number in between of that string eg.-Amount 30002.234 successfully credited to your account . now i have to match this pattern in such a way that even if decimal is not there pattern should match ,how i will do this using regular expression
what is risks of testing a project?
is it possible to check the text displayed in the tool tip using QTP? if so, how?
How we know the qtp has used the smart identification process for identification of the object.
Can any one give me some basic VB script used in QTP ?As i am new in QTP.Give sample VB script used in QTP? PLZ
Among the 4 capture levels, Complete, Partial, Minimal, None. which one is mostly used?