Hi Justin, have you ever try to click option using JavaScript click, it is not choosing as selenium click towards the option would choose the option . But button click remain the same for both, do know why it is ?
On 23-Jun-2018 1:06 AM, "Justin Ko" <[email protected]> wrote: Do you try using the :id locator? It looks like you might have crossed your attributes/values - ie the attempts are checking the "fielddisplayname" attribute, but looking for the id value. Try: @browser.a(id: "Employee_ID").click If #click isn't working, you could also try #click! @browser.a(id: "Employee_ID").click! - Justin On Friday, June 22, 2018 at 12:36:22 PM UTC-4, christina wrote: > Is not ok because all other attributes have the same link. > > I have to identify in a unique way. > > Please let me know how.... Thank you! > > On Fri, Jun 22, 2018 at 11:31 AM, c w <[email protected]> wrote: > >> That worked: >> >> @browser.link(:class, "peoplefield editable editable-click >> editable-empty").fire_event:click >> >> >> >> ---------- Forwarded message ---------- >> From: c w <[email protected]> >> Date: Fri, Jun 22, 2018 at 11:03 AM >> Subject: how can I click an <a href=javascript:; .... that is used to go >> on edit mode for a field >> To: [email protected] >> >> >> >> Hi all, >> >> Please help me and Thank you! >> In order to edit these attribute I have to click on the "empty" which is >> a javascript:; >> >> Please can one tell me how can I click on the Employee_id field to edit... >> If I will be able to do this tho others should be similar. >> >> I have try few things but these are not working: >> @browser.a(fielddisplayname: "Employee_ID").click >> @browser.a(fielddisplayname: "Employee_ID").fire_event:click >> @browser.a(:class, ' peoplefield editable editable-click >> editable-empty').click >> >> @browser.a(fielddisplayname: "Employee_ID").fire_event('onclick') >> @browser.link(:xpath, "//a[@onclick='javascript:;']").click >> >> >> >> >> >> >> >> >> >> >> >> > -- -- Before posting, please read https://github.com/watir/watir_meta/wiki/Guidelines-for-Posting-to-Watir-General-Google-Group. 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/d/optout. -- -- Before posting, please read https://github.com/watir/watir_meta/wiki/Guidelines-for-Posting-to-Watir-General-Google-Group. 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/d/optout.
