since they are lis you want to grab their text as they probably dont have a value set
On Mon, Sep 30, 2013 at 11:53 AM, sp22 <[email protected]> wrote: > I am trying to capture the values within a dropdown list (which is > populated based on some other values) and compare it with an expected set > of values. Thanks! > > > On Monday, September 30, 2013 10:10:25 AM UTC-4, Dan wrote: >> >> I think it would be helpful to know what you're trying to accomplish by >> doing this, but you could do it like below. >> >> values = b.ul.lis.collect{|x|x.value} >> >> On Monday, September 30, 2013 8:46:06 AM UTC-4, sp22 wrote: >>> >>> I have html code like - >>> >>> <div id="unique_id"> >>> <div class="rcbScroll rcbWidth"> >>> <ul class="rcbList"> >>> <li class="rcbItem">Value1</li> >>> <li class="rcbItem">Value2</li> >>> <li class="rcbItem">Value3</li> >>> <li class="rcbItem">Value4</li> >>> <li class="rcbItem">Value5</li> >>> </ul> >>> </div> >>> </div> >>> >>> Can you please suggest how I can create an array with the values in the >>> list? >>> >>> Thanks! >>> >> -- > -- > Before posting, please read http://watir.com/support. In short: search > before you ask, be nice. > > [email protected] > http://groups.google.com/group/watir-general > [email protected] > > --- > You received this message because you are subscribed to the Google Groups > "Watir General" group. > To unsubscribe from this group and stop receiving emails from it, send an > email to [email protected]. > For more options, visit https://groups.google.com/groups/opt_out. > -- -- Before posting, please read http://watir.com/support. In short: search before you ask, be nice. [email protected] http://groups.google.com/group/watir-general [email protected] --- You received this message because you are subscribed to the Google Groups "Watir General" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/groups/opt_out.
