Re: [wtr-general] Re: how can I click an

2018-06-25 Thread Titus Fortner
The error you show here is related to a text field, with a very ugly xpath 
locator, it is not the error you would get for it not finding 
@browser.a(id: "Employee_ID") regardless of whether you are using `#click` 
or `#click!`.

You should never have to use XPath with Watir.


On Monday, June 25, 2018 at 6:58:26 PM UTC+5:30, christina wrote:
>
>
> Happy week all!
>
>
> Thank you!
>
> 1. If I use:  is not working
>
> @browser.a(id: "Employee_ID").click!
>
>   timed out after 30 seconds, waiting for true condition on 
> # {:xpath=>"//*[@id=\"infotab_11\"]/table/tbody/tr[3]/td[2]/span/div/form/div/div[1]/div[1]/input",
>  
> :tag_name=>"input"}> (Watir::Wait::TimeoutError)
>   ./features/support/pages/peopleAdminPage.rb:35:in `set_given_names'
>   ./features/support/pages/peopleAdminPage.rb:225:in `add_employee'
>   ./features/step_definitions/adminPeopleSteps.rb:17:in `/^I add an 
> employee$/'
>   features/features/qaeeAddEEAndDep.feature:20:in `Then I add an 
> employee'
>
>
> 2. If I use xpath is working
>
>
> @browser.link(:xpath, '//*[@id="Employee_ID"]').click! 
> or
> @browser.link(:xpath, '//*[@id="Employee_ID"]').click
>
>
>
> So I go with xpath.
>
>
> Please tell me if there is any difference between click and click!
>
> or it doesn't matter what we use.
>
> Thank you!
>
>
> On Fri, Jun 22, 2018 at 8:20 PM, Justin Ko  > wrote:
>
>> @rajagopalan, I don't know enough about the internal workings of 
>> JavaScript or Webdriver to be sure. But my guess would be:
>>
>>- Browsers do not fully support click events for  elements - 
>>eg https://stackoverflow.com/q/3487263/1200545
>>- As a result WebDriver has defined special logic simulating a click, 
>>which includes interacting with the select element - see definition 
>>https://www.w3.org/TR/webdriver/#element-click
>>
>> Justin
>>
>>
>> On Friday, June 22, 2018 at 3:39:05 PM UTC-4, rajagopalan madasami wrote:
>>>
>>> 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"  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  wrote:

> That worked:
>
> @browser.link(:class, "peoplefield editable editable-click 
> editable-empty").fire_event:click  
>
>
>
> -- Forwarded message --
> From: c w 
> Date: Fri, Jun 22, 2018 at 11:03 AM
> Subject: how can I click an  go on edit mode for a field
> To: watir-...@googlegroups.com
>
>
>
> 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.
>>>  
>>> watir-...@googlegroups.com
>>> http://groups.google.com/group/watir-general
>>> watir-genera...@googlegroups.com
>>> --- 
>>> 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 watir-genera...@googlegroups.com.
>>> 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.
>>  
>> watir-...@googlegroups.com 
>> 

Re: [wtr-general] Re: how can I click an

2018-06-25 Thread rajagopalan madasami
Justin,

I think this is clearly giving me the clue that WebDriver is also using
javascript inside, eh? because they are performing all the mouse move,
triggering onclick and all the rest of the step, so they are backing up
Javascript comment and creating the exe file. It seems to be that's the
case. yes? If it is not what else can be used to do mouse hover and
onclick?

On Sat, Jun 23, 2018 at 5:50 AM, Justin Ko  wrote:

> @rajagopalan, I don't know enough about the internal workings of
> JavaScript or Webdriver to be sure. But my guess would be:
>
>- Browsers do not fully support click events for  elements -
>eg https://stackoverflow.com/q/3487263/1200545
>- As a result WebDriver has defined special logic simulating a click,
>which includes interacting with the select element - see definition
>https://www.w3.org/TR/webdriver/#element-click
>
>
> Justin
>
>
> On Friday, June 22, 2018 at 3:39:05 PM UTC-4, rajagopalan madasami wrote:
>>
>> 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"  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  wrote:
>>>
 That worked:

 @browser.link(:class, "peoplefield editable editable-click
 editable-empty").fire_event:click



 -- Forwarded message --
 From: c w 
 Date: Fri, Jun 22, 2018 at 11:03 AM
 Subject: how can I click an >>> go on edit mode for a field
 To: watir-...@googlegroups.com



 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.
>>
>> watir-...@googlegroups.com
>> http://groups.google.com/group/watir-general
>> watir-genera...@googlegroups.com
>> ---
>> 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 watir-genera...@googlegroups.com.
>> 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.
>
> watir-general@googlegroups.com
> http://groups.google.com/group/watir-general
> watir-general+unsubscr...@googlegroups.com
> ---
> 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 watir-general+unsubscr...@googlegroups.com.
> 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.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com
--- 
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 watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [wtr-general] Re: how can I click an

2018-06-25 Thread rajagopalanmadasami

click performs selenium click but click! performs javascript click

I suspect the element you want click is not a click, that's what 

@browser.a(id: "Employee_ID").click!

is not working 

but 

@browser.link(:xpath, '//*[@id="Employee_ID"]').click! 

working.

when you write xpath, you don't need to customize the by using customized 
tag like link(),a(),button(), because xpath is about how you reach from one 
element to another element. 

Can you give me the html element which you try to click, I will let you 
know what problem you have.

On Monday, June 25, 2018 at 6:58:26 PM UTC+5:30, christina wrote:
>
>
> Happy week all!
>
>
> Thank you!
>
> 1. If I use:  is not working
>
> @browser.a(id: "Employee_ID").click!
>
>   timed out after 30 seconds, waiting for true condition on 
> # {:xpath=>"//*[@id=\"infotab_11\"]/table/tbody/tr[3]/td[2]/span/div/form/div/div[1]/div[1]/input",
>  
> :tag_name=>"input"}> (Watir::Wait::TimeoutError)
>   ./features/support/pages/peopleAdminPage.rb:35:in `set_given_names'
>   ./features/support/pages/peopleAdminPage.rb:225:in `add_employee'
>   ./features/step_definitions/adminPeopleSteps.rb:17:in `/^I add an 
> employee$/'
>   features/features/qaeeAddEEAndDep.feature:20:in `Then I add an 
> employee'
>
>
> 2. If I use xpath is working
>
>
> @browser.link(:xpath, '//*[@id="Employee_ID"]').click! 
> or
> @browser.link(:xpath, '//*[@id="Employee_ID"]').click
>
>
>
> So I go with xpath.
>
>
> Please tell me if there is any difference between click and click!
>
> or it doesn't matter what we use.
>
> Thank you!
>
>
> On Fri, Jun 22, 2018 at 8:20 PM, Justin Ko  > wrote:
>
>> @rajagopalan, I don't know enough about the internal workings of 
>> JavaScript or Webdriver to be sure. But my guess would be:
>>
>>- Browsers do not fully support click events for  elements - 
>>eg https://stackoverflow.com/q/3487263/1200545
>>- As a result WebDriver has defined special logic simulating a click, 
>>which includes interacting with the select element - see definition 
>>https://www.w3.org/TR/webdriver/#element-click
>>
>> Justin
>>
>>
>> On Friday, June 22, 2018 at 3:39:05 PM UTC-4, rajagopalan madasami wrote:
>>>
>>> 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"  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  wrote:

> That worked:
>
> @browser.link(:class, "peoplefield editable editable-click 
> editable-empty").fire_event:click  
>
>
>
> -- Forwarded message --
> From: c w 
> Date: Fri, Jun 22, 2018 at 11:03 AM
> Subject: how can I click an  go on edit mode for a field
> To: watir-...@googlegroups.com
>
>
>
> 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.
>>>  
>>> watir-...@googlegroups.com
>>> http://groups.google.com/group/watir-general
>>> watir-genera...@googlegroups.com
>>> --- 
>>> 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 watir-genera...@googlegroups.com.
>>> For more options, visit 

Re: [wtr-general] Re: how can I click an

2018-06-25 Thread c w
Happy week all!


Thank you!

1. If I use:  is not working

@browser.a(id: "Employee_ID").click!

  timed out after 30 seconds, waiting for true condition on
#"//*[@id=\"infotab_11\"]/table/tbody/tr[3]/td[2]/span/div/form/div/div[1]/div[1]/input",
:tag_name=>"input"}> (Watir::Wait::TimeoutError)
  ./features/support/pages/peopleAdminPage.rb:35:in `set_given_names'
  ./features/support/pages/peopleAdminPage.rb:225:in `add_employee'
  ./features/step_definitions/adminPeopleSteps.rb:17:in `/^I add an
employee$/'
  features/features/qaeeAddEEAndDep.feature:20:in `Then I add an
employee'


2. If I use xpath is working


@browser.link(:xpath, '//*[@id="Employee_ID"]').click!
or
@browser.link(:xpath, '//*[@id="Employee_ID"]').click



So I go with xpath.


Please tell me if there is any difference between click and click!

or it doesn't matter what we use.

Thank you!


On Fri, Jun 22, 2018 at 8:20 PM, Justin Ko  wrote:

> @rajagopalan, I don't know enough about the internal workings of
> JavaScript or Webdriver to be sure. But my guess would be:
>
>- Browsers do not fully support click events for  elements -
>eg https://stackoverflow.com/q/3487263/1200545
>- As a result WebDriver has defined special logic simulating a click,
>which includes interacting with the select element - see definition
>https://www.w3.org/TR/webdriver/#element-click
>
>
> Justin
>
>
> On Friday, June 22, 2018 at 3:39:05 PM UTC-4, rajagopalan madasami wrote:
>>
>> 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"  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  wrote:
>>>
 That worked:

 @browser.link(:class, "peoplefield editable editable-click
 editable-empty").fire_event:click



 -- Forwarded message --
 From: c w 
 Date: Fri, Jun 22, 2018 at 11:03 AM
 Subject: how can I click an >>> go on edit mode for a field
 To: watir-...@googlegroups.com



 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.
>>
>> watir-...@googlegroups.com
>> http://groups.google.com/group/watir-general
>> watir-genera...@googlegroups.com
>> ---
>> 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 watir-genera...@googlegroups.com.
>> 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.
>
> watir-general@googlegroups.com
> http://groups.google.com/group/watir-general
> watir-general+unsubscr...@googlegroups.com
> ---
> 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 watir-general+unsubscr...@googlegroups.com.
> 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, 

Re: [wtr-general] Re: how can I click an

2018-06-22 Thread Justin Ko
@rajagopalan, I don't know enough about the internal workings of JavaScript 
or Webdriver to be sure. But my guess would be:

   - Browsers do not fully support click events for  elements - eg 
   https://stackoverflow.com/q/3487263/1200545
   - As a result WebDriver has defined special logic simulating a click, 
   which includes interacting with the select element - see definition 
   https://www.w3.org/TR/webdriver/#element-click
   
Justin


On Friday, June 22, 2018 at 3:39:05 PM UTC-4, rajagopalan madasami wrote:
>
> 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" > 
> 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  wrote:
>>
>>> That worked:
>>>
>>> @browser.link(:class, "peoplefield editable editable-click 
>>> editable-empty").fire_event:click  
>>>
>>>
>>>
>>> -- Forwarded message --
>>> From: c w 
>>> Date: Fri, Jun 22, 2018 at 11:03 AM
>>> Subject: how can I click an >> on edit mode for a field
>>> To: watir-...@googlegroups.com
>>>
>>>
>>>
>>> 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.
>  
> watir-...@googlegroups.com 
> http://groups.google.com/group/watir-general
> watir-genera...@googlegroups.com 
> --- 
> 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 watir-genera...@googlegroups.com .
> 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.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com
--- 
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 watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


Re: [wtr-general] Re: how can I click an

2018-06-22 Thread rajagopalan madasami
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"  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  wrote:
>
>> That worked:
>>
>> @browser.link(:class, "peoplefield editable editable-click
>> editable-empty").fire_event:click
>>
>>
>>
>> -- Forwarded message --
>> From: c w 
>> Date: Fri, Jun 22, 2018 at 11:03 AM
>> Subject: how can I click an > on edit mode for a field
>> To: watir-...@googlegroups.com
>>
>>
>>
>> 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.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com
---
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 watir-general+unsubscr...@googlegroups.com.
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.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com
--- 
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 watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[wtr-general] Re: how can I click an

2018-06-22 Thread Justin Ko
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 > 
> wrote:
>
>> That worked:
>>
>> @browser.link(:class, "peoplefield editable editable-click 
>> editable-empty").fire_event:click  
>>
>>
>>
>> -- Forwarded message --
>> From: c w >
>> Date: Fri, Jun 22, 2018 at 11:03 AM
>> Subject: how can I click an > on edit mode for a field
>> To: watir-...@googlegroups.com 
>>
>>
>>
>> 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.

watir-general@googlegroups.com
http://groups.google.com/group/watir-general
watir-general+unsubscr...@googlegroups.com
--- 
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 watir-general+unsubscr...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


[wtr-general] Re: How can I click on this button / form

2010-03-07 Thread HeG
Hi,

Thanks for your help : this fix it browser.link(:xpath,//i...@src='/
button_genomfor_fund.gif']/..).click

As this url is generated each time I can not use it:
browser.link(:href,https://www.Race.com/swiki/
4phoyzf6u9qheb2gj036471fj?_s=DeMjZhiczxzzG...).click

Have a nice WE.

B.R
H.E


On Mar 7, 9:28 am, windy lyfi2...@sina.com wrote:
 if you can use href attribute, try  
 browser.link(:href,https://www.Race.com/swiki/4phoyzf6u9qheb2gj036471fj?_s=DeMjZhiczxzzG...;).click
 or you can use xpath, code like  
 browser.link(:xpath,//i...@src='/button_genomfor_fund.gif']/..).click

 Sun, 07 Mar 2010 15:31:42 +0800 HeG ekenberg.hen...@gmail.com д :

  Hi,

  I want to click on the image/button ( img alt= src=/
  button_genomfor_fund.gif/ )

  Any advice how I can code this with watir.

  Code:

  form accept-charset=utf-8 method=post action=https://
 www.Race.com/swiki/4phoyzf6u9qheb2gj036471fj id=forma
  onclick=document.forms['form'].submit() href=https://www.Race.com/
  swiki/4phoyzf6u9qheb2gj036471fj?
  _s=DeMjZhiczxzzGeAhamp;_k=pDVYZqbDamp;1img alt= src=/
  button_genomfor_fund.gif//aa
  onclick=document.forms['form'].submit() href=https://www.Race.com/
  swiki/4phoyzf6u9qheb2gj036471fj?
  _s=DeMjZhiczxzzGeAhamp;_k=pDVYZqbDamp;2img alt= src=/
  button_avbryt_fund.gif//adivinput name=_s
  value=DeMjZhiczxzzGeAh type=hidden class=hidden/input
  name=_k value=pDVYZqbD type=hidden class=hidden/
  /div

  thanks for your help / advice

  B.R
  H.E

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


[wtr-general] Re: How can i click CTRL key + Link in Watir

2009-08-17 Thread Dylan

See my reply to your other message, and please only create one
discussion per topic at a time, thanks. :)

-Dylan

On Aug 17, 12:05 am, Bhavesh bhavesh1_sha...@yahoo.com wrote:
 Hi ,

 I have to click CTRL key + link using watir.

 Is anybody know how to do it?

 Actually i can tmodify any setting in IE, os i have to press CTRL key
 manually and then link to open an link.

 But for automation, i have to do it using WATIR

 Any help is appreciated.

 Bhavesh
--~--~-~--~~~---~--~~
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
-~--~~~~--~~--~--~---