Ok no problem. I was just checking to make
sure everything worked ok. No rush. From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Paatsch, Bernd Got a little sidetracked. variable =
$ie.getDocument().getElementsByName("Add_member[]”); This gives me the list of all three input
elements. Now I need to find the right index. That's what I am working on right
now. From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Sergio Pinon Did you try the method I gave you? I
wanted to know if it worked. Sergio From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Paatsch, Bernd The table is generated by an underlining database and the
values are different almost every time. <tr> <td> <input
type="checkbox" name="Add_member[]"
value="25"> </td> <td> Test1
</td></tr> From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Cain, Mark You don’t need to just try something
like this. $ie.checkbox(:name,
/Add_member/i, “35”).set You can use regular expressions for your
attribute name if you know part of what that name will be at
runtime—although it does get tricky when attribute names for an object
are the same, in that case you can use :index. Indexes are 1 based
currently (although I heard some rumbling as to think they will soon be zero
based) and start with the first one on the page and continue through the last
one on the page. --Mark From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On
Behalf Of Paatsch, Bernd I have almost none _javascript_ experience.
How do I get the underlying _javascript_ object of that page? From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Sergio Pinon Well the other thing to do is try the code
below. What you do is get the underlying _javascript_ object of the page and then
interact with it as you would with _javascript_. You get all the elements with the
name you supply and then access the one you want using the indexer on that
array. Then you just set the checked property of that object to true and it
should work. Let me know how it turns out. ie_browser.getDocument().getElementsByName(“Add_member[]”)[index
of control].checked = true; From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Paatsch, Bernd Unfortunately I do not know the value
beforehand. From:
[EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Sergio Pinon Do you know the value of the checkbox
beforehand? If you do then just use this method: Ie_browser.checkbox(:name,
“Add_member[]”, “35”).set(); This should be good to go. Sergio From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On
Behalf Of Paatsch, Bernd Hello,
I
have following html code and like to select the checkbox for "Test3".
How can I do that? <input
type="checkbox" name="Add_member[]"
value="25"></td><td> Test1</td><td>
Subscriber</td><td>208</td></tr> Thanks.
|
_______________________________________________ Wtr-general mailing list Wtr-general@rubyforge.org http://rubyforge.org/mailman/listinfo/wtr-general