Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Click checkbox using its label name.
#1
Solved: 7 Years, 7 Months, 1 Week ago Sad 
Hi People I Need a Great help from you Guys and much Thankful and appreciated.

I have 10 checkboxes in a page and it has respective labels like

abc <Checkbox1>
cab <Checkbox2>
.
.
.
.

abc is a label name and checkbox 1 is a checkbox ... Now u guys got the picture.


I need to click checkbox1 by sending abc as parameter.

If the parameter exists in the page click the respective checkbox..

I have written the following code.Please give a look up and provide your solution.

Code:
Set objCheckbox = Description.Create
objCheckbox("micclass").value = "WebCheckBox"

Set objCheckboxcoll = Browser("abc").Page("abc").WebTable("BranchSelect").ChildObjects(objCheckbox)
Msgbox objCheckboxcoll.count

'Msgbox objWebElementcoll(0).GetROProperty("Innertext")

'For i = 1 To objCheckboxcoll.count
'    If Trim(objCheckboxcoll(i).GetROProperty("label")) = Trim("NORTH HAZARD") Then
'        objCheckboxcoll(i).set "ON"
'    End If    
'Next
Reply


Messages In This Thread
Click checkbox using its label name. - by venkatesh9032 - 08-06-2015, 04:42 PM

Possibly Related Threads…
Thread Author Replies Views Last Post
  Help with Select checkbox from data table value jayraocourts 0 1,069 11-01-2019, 10:25 PM
Last Post: jayraocourts
  Childobject return wrong checkbox count.. VpnQTP 1 2,592 04-09-2015, 09:07 PM
Last Post: babu123
  How to select dynamic checkbox from web dropdown QA_Newbie 2 4,479 07-20-2014, 09:40 PM
Last Post: QA_Newbie
  How To pick up the particular mail in Post Login Gmail page and click on Checkbox akhandesh 0 2,705 12-02-2013, 01:35 PM
Last Post: akhandesh
  How to select the first checkbox ramya511 3 5,405 05-22-2013, 01:45 PM
Last Post: learnQtptips

Forum Jump:


Users browsing this thread: 1 Guest(s)