Thank you all for replying to this thread and answering my question.<br><br>
Angrez, I had difficulty using 'attribute_value'. Here is how I used it along
with the html code.<br><br>
HTML Code:<br>
<tTD><iINPUT id=MainLogin_UserName name=MainLogin$UserName> <sSPAN
id=MainLogin_UserNameRequired title="User Name is required." style="VISIBILITY:
hidden; COLOR: red" controltovalidate="MainLogin_UserName" errormessage="User
Name is required." validationGroup="MainLogin" initialvalue
isvalid="true">*</sSPAN></tTD></tTR><br><br>
Ruby/Watir Code:<br>
str_value=$browser.span(:id,
"MainLogin_UserNameRequired").attribute_value("style")<br>
puts str_value
<br><br>
Output:<br>
#<WIN32OLE:0x2c4d108>
<br><br>
I do have two solutions that work (see below) but I'm curious of how this might
work. One other thing, for others, is the 'attribute_value' does not work for
Watir version 1.4; use 1.5.<br><br>
Zeljko, thanks this worked.<br><br>
nchristie, thanks this worked.<br><br>
I did not try the 'walk DOM tree for checking of disabled or non-visible
elements'; this looks 'advanced'. :) <br><br>
Brad
---------------------------------------------------------------------
Posted via Jive Forums
http://forums.openqa.org/thread.jspa?threadID=5879&messageID=16765#16765
_______________________________________________
Wtr-general mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/wtr-general