Have found a solution.
 
I firstly need to fire_event("onmouseover") which selects the item then 
fire_event("onclick").
 
Thank you all for your comments.
 

On Wednesday, May 8, 2013 10:39:16 AM UTC+1, Marc Westwood wrote:

> Yes it works in terms of its clicks on the item in the select list because 
> I can see the item in the list go yellow when it clicks but while is clicks 
> it does not actually select the item.
>  
> I can't see anything about a onclick mentioned.
>  
> I've tried .click fire_event('onclick') mousedown mouseup onchange nothing 
> seems to work.
>  
> I have the same issue with other drop down lists in our application as 
> well but the other drop down lists have different HTML they are <options 
> tag in the html.
>  
> Sorry I'm new to all this.
>  
>
> On Friday, May 3, 2013 6:00:11 PM UTC+1, Super Kevy wrote:
>
>> Did this work? 
>> browser.div(:class, "selectable_list").li(:id, "_item_2").click 
>> Against this code sample 
>>
>> <li><a id="_item_1" window="[object]" ..... 
>> Text = "DEF - 100 DEF" 
>>
>> I think you confirmed  to zeljko browser.link(:text,"DEF - 100 
>> DEF").click  worked 
>>
>> Your sample code fragment is somewhat inadequate to answer your issue 
>> I assume the html really looks like this: 
>> <li><a id="_item1" ...other anchor attributes..... >DEF - 100 DEF</a></ 
>> li> 
>>
>> Do you see any onchange, onclick events  in the div selectable_list, 
>> in the anchor, or list item? 
>>
>>
>> On May 2, 6:56 am, Marc Westwood <[email protected]> wrote: 
>> > I have tried. 
>> > 
>> > .div(:class, "selectable_list").li(:id, "_item_2").click 
>> > .div(:class, "selectable_list").select 'DEF - 100 DEF' 
>> > .select_list(:id, "selectable_list").select 'DEF - 100 DEF' 
>> > 
>> > I would like to click on using the text. 
>> > 
>> > 
>> > 
>> > 
>> > 
>> > 
>> > 
>> > On Thursday, May 2, 2013 7:57:55 AM UTC+1, Željko Filipin wrote: 
>> > > On Wed, May 1, 2013 at 3:52 PM, Marc Westwood 
>> > > <[email protected]<javascript:> 
>>
>> > > > wrote: 
>> > 
>> > >> I am having problems selecting items from a drop down list, I can 
>> get the 
>> > >> drop down list to open but am unable to select an item within the 
>> list. 
>> > 
>> > > You are not dealing with select list (select tag), but with unordered 
>> list 
>> > > (ul tag). What do you want to click? What have you tried so far? 
>> > 
>> > > Željko 
>> > > -- 
>> > >https://leanpub.com/watirbook 
>>
>

-- 
-- 
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.


Reply via email to