What will be the test script in QTP to test a ComboBox
where a user has to select more than two items????
Answer Posted / maheshbabu.t
Hi This Mahesh
I am sending the Descriptive Progarme see below
Function selectWebItem(webListName,ItemName,webItemIndexVal)
ClearDialogs()
strHandle = Window
("RegExpWndClass:=IEFrame","index:=0" ).GetROProperty
("hWnd")
Set gobjBrowser = Browser("hWnd:=" & strHandle)
Set gobjPage = gobjBrowser.Page("index:=1")
gobjPage.Sync
Set objDescription = Description.Create()
objDescription("Class Name").Value = "WebList"
objDescription("html tag").Value = "SELECT"
objDescription("name").Value = webListName
If gobjPage.WebList(objDescription).exist(0) Then
gobjPage.WebList(objDescription).select
ItemName
else
objDescription
("index").value=webItemIndexVal
If gobjPage.WebList(objDescription).exist
(0) Then
gobjPage.WebList
(objDescription).select ItemName
else
testPassCntr=testPassCntr+1
End if
End If
End Function
| Is This Answer Correct ? | 2 Yes | 2 No |
Post New Answer View All Answers
can any body tell me how i create a simple script and apply output value on it .pls send me a step by step process
what are the challenges you have faced while testing web based application using the automation tools ?
.have you ever written compiled module? if yes , tell me about some of the function that you wrote.
how to explain a claims and insurance project?
Describe synchronization point.
Hi All, How to Compare two strings character by character in QTP
If you have two monitors one is of 19inch and the 2nd one is of 24inch,if you want to write same QTP script in both the two monitors is there any changes required in the script?
Hello everyone! I am just writing a small test for a windows application. I have a problem with a text output value. The value i am trying to catch is presented in a scrollable textbox. When the text is too long, only a portion of it gets captured. Do you have any experience with this?
How do you convert manual test cases to automated test cases?
What is the keyword view and expert view in qtp?
Hi,All How to create a link in excel sheet using qtp
How many scripts did you have?
What is the difference between rational rose and QTP?
Excel sheet having some datas and some datas present in the application (in table). How will you compare these two datas? Write code to fetch datas from Excel sheet.
What is an object repository?