# Mechanize | trouble with select box (drop down box)

**URL:** <https://www.ruby-forum.com/t/mechanize-trouble-with-select-box-drop-down-box/114556>\
**Category:** Ruby\
**Created:** [September 15, 2007, 4:48am UTC](https://www.ruby-forum.com/t/mechanize-trouble-with-select-box-drop-down-box/114556 "2007-09-15T04:48:40Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![yeago](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/y/eada6e/32.png) [@yeago](https://www.ruby-forum.com/u/yeago)\
**Post date:** [September 15, 2007, 4:48am UTC](https://www.ruby-forum.com/t/mechanize-trouble-with-select-box-drop-down-box/114556/1 "2007-09-15T04:48:40Z")

</div>

For the life of me, I can’t seem to access the form ‘\_ddlFilterFormat’  
in any other way than the below awkward code:

initPage.forms.name(“form1”).fields.each{|f|  
if(f.name == “\_ddlFilterFormat”)  
f.options.each{|o|

```
            }
    end

```

}

initPage.forms.name(“form1”).fields("\_ddlFilterFormat").options.each{|f|  
puts f.text  
#…yields nothing! Never loops!  
}
