Well, it works for me. I also downloaded tarball today.

HTML:

<html>
<body>
<input type=radio name=AssociateWith value=Outlet>
<input type=radio name=AssociateWith value=WebSite>
<input type=radio name=AssociateWith value=Distributor>
</body>
</html>

IRB:

C:\Documents and Settings\zfilipin\My Documents\Tests\test>irb
irb(main):001:0> require 'watir'
=> true
irb(main):002:0> ie = Watir::IE.attach(:title, //)
=> #<Watir::IE:0x29605d8
@error_checkers=[#<Proc:[EMAIL 
PROTECTED]:/ruby/lib/ruby/site_ruby/1.8/watir.rb:1
135>], @defaultSleepTime=0.1, @activeObjectHighLightCol
or="yellow", @pageHasReloaded=false, @enable_spinner=false,
@url_list=["file://C:\\Documents and Settings\\zfilipin\\My
Documents\\Tests\\test\\html\\r.htm"
], @logger=#<Watir::DefaultLogger:0x295fff0 @level=2,
@datetime_format="%d-%b-%Y %H:%M:%S", @progname=nil,
@logdev=#<Logger::LogDevice:0x295f7c8 @shift_size
=nil, @shift_age=nil, @filename=nil, @dev=#<IO:0x284e7d0>>>,
@typingspeed=0.08, @form=nil, @ie=#<WIN32OLE:0x2960098>,
@down_load_time=0.125>
irb(main):003:0> ie.radios.each do|r|
irb(main):004:1* puts r
irb(main):005:1> end
type:         radio
id:
name:         AssociateWith
value:        Outlet
disabled:     false
type:         radio
id:
name:         AssociateWith
value:        WebSite
disabled:     false
type:         radio
id:
name:         AssociateWith
value:        Distributor
disabled:     false
=> 0 

Zeljko

-----Original Message-----
From: [EMAIL PROTECTED]
[mailto:[EMAIL PROTECTED] On Behalf Of Shao Kang Tat
Sent: Friday, July 29, 2005 3:52 PM
To: [email protected]
Subject: [Wtr-general] radio button support

Hey,

I got the latest version of watir from the tarball (thanks Zeljko).  I
currently have a page that has 3 radio buttons..here's the html:

<input type=radio name=AssociateWith value=Outlet
<input type=radio name=AssociateWith value=WebSite>
<input type=radio name=AssociateWith value=Distributor>


when I do: 

ie.radios.each do|r|
puts r
end

I get the error:  WIN32OLERuntimeError: Unknown property or method `value'

if I just do a puts r.name I get blanks. 

Is there a current fix for this?

Shao

_______________________________________________
Wtr-general mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/wtr-general

_______________________________________________
Wtr-general mailing list
[email protected]
http://rubyforge.org/mailman/listinfo/wtr-general

Reply via email to