It is 1-based
ie.textField(:index, 1).set("I did it!")

--Mark


-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Nathan
Sent: Wednesday, November 15, 2006 12:28 PM
To: wtr-general@rubyforge.org
Subject: Re: [Wtr-general] Find parent table index from a specific
elementwithin

So if I understand correctly, you have a table that looks something like
the following:

[code]
<table border=1>
  <tr>
    <td>...</td>
    <td><span>findme</span></td>
    <td><input type=text value=""></input></td>
    <td>...</td>
  </tr>
</table>
[/code]

And you want to located the text field and enter some value into it?
Well you could do the following:  Assuming that this text field is the
first and only text field on the page, then some like this code would be
able to access it and enter the value "I did it!" into that text field:

ie.textField(:index, "0").set("I did it!")

Does that make sense or am I way off?
---------------------------------------------------------------------
Posted via Jive Forums
http://forums.openqa.org/thread.jspa?threadID=5270&messageID=14675#14675
_______________________________________________
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general
_______________________________________________
Wtr-general mailing list
Wtr-general@rubyforge.org
http://rubyforge.org/mailman/listinfo/wtr-general

Reply via email to