02-27-2013, 04:42 PM
(This post was last modified: 02-27-2013, 04:43 PM by pradeep singh.)
Hi,
I got solution and now it works fine.
'**************************************************
Step 1. Create a function
Step 2. Click on Label Webelement (so that list pop can open)
Step 3. Click on Webelement (The value to be select)
'*************************************************
It solved my problem.
I got solution and now it works fine.
'**************************************************
Step 1. Create a function
Step 2. Click on Label Webelement (so that list pop can open)
Step 3. Click on Webelement (The value to be select)
Code:
fnDivSelectList sDefaultValue,sValueToSelect
Function fnDivSelectList(sDefaultValue,sValue)
'++++++++++++++++++++++++++++++++++++++
' Function Description: This function will select the value from a list (Not Weblist ,but list under DIV as a Webelement)
' Author : Pradeep
' Date : 26- Feb-2013
' Input parameter : Default value of List,Value to be select
' Output :
' Remarks :
'++++++++++++++++++++++++++++++++++++++
Set olistLabel=Browser("title:=.*").Page("title:=.*").WebElement("html tag:=LABEL","innertext:="&sDefaultValue)
olistLabel.click
Set oListValue=Browser("title:=.*").Page("title:=.*").WebElement("html tag:=LI","class:=ui-selectonemenu-item.*","innertext:="& sValue)
oListValue.click
Set olistLabel=Nothing
Set oListValue=Nothing
End Function
It solved my problem.