Ad Home

Theme images by kelvinjay. Powered by Blogger.

Travel

Header Ads

Java

Selenium

UFT

Framework

General QA Concept

BDD

» » check all checkboxes in a webpage/window

script to check all checkboxes in a webpage.
Set a=Description.Create
a("html tag").value="input"
a("type").value="checkbox"
Set b=Browser("name:=").Page("title:=").childobjects(a)
c=b.count
msgbox c
For i=0 to c-1
b(i).set "on"
Next

«
Next
Newer Post
»
Previous
Older Post

3 comments:

  1. thanks it is a great help

    ReplyDelete
  2. jus let me know if u stuck anywhere.

    ReplyDelete
  3. Can I use the below code to check all check boxes in a webpage?

    for i= 0 to checkboxcnt

    Browser("browser").page("page").webcheckbox("name:=checkbox",Index:="&i).Set "ON"

    Next

    ReplyDelete