Dear George, The privious trouble has alreadly been clear, I use the "Select Element by Click" functon to get the attribute. But then a follow problem come in... In my test page, the drop down list are all <div> which were created by JS. I used click() method to click the item, but nothing happened, then I use click_no_wait() method, but it did not work yet. At last, I use fire_event() method just as following, but it also did not work! menu.div(:text, 'Internal Control System').fire_event("onMouseOver") menu.div(:text, 'Internal Control System').fire_event("onMouseDown") menu.div(:text, 'Internal Control System').fire_event("onClick") menu.div(:text, 'Internal Control System').fire_event("ondblclick") menu.div(:text, 'Internal Control System').click_no_wait Attached is the drop down list.
PS: Is there a method can operate a right click? Eason 2009-08-28 发件人: George 发送时间: 2009-08-28 04:20:26 收件人: Watir General 抄送: 主题: [wtr-general] Re: How can I get the attribute in the attached? What sort of information is the developer toolbar giving you? Have you tried using the :index attribute? On Aug 26, 8:38 pm, "Eason" <nbkhic...@gmail.com > wrote: > Dear All, > Please view the image in the attached. > I want to get the arrtibute of the item "Quality Management". > The drop-down list is a div which is created by javascript, I try to use IE > devolep tool to get the attribute of the item, but I find that it is > impossible, when I use the tool onfocus to the item, the item will > disappear, so I can not fetch the details of this item. > Can anyone tell me how to get the attribute? > > Eason > 2009-08-27 > > 截图00.bmp > 516KViewDownload --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Watir General" group. To post to this group, send email to watir-general@googlegroups.com Before posting, please read the following guidelines: http://wiki.openqa.org/display/WTR/Support To unsubscribe from this group, send email to watir-general-unsubscr...@googlegroups.com For more options, visit this group at http://groups.google.com/group/watir-general -~----------~----~----~----~------~----~------~--~---
<<attachment: 00.JPG>>