I do believe that Brian is right - the element you are trying to click is
most probably temporarily overlaid due to some animation. Especially if the
error is intermittent and varies as you describe it.

waitFor will help if you take the time to analyse what is being animated at
that particular point in time and wait for it to finish.

Also, you should not need to scroll anything - WebDriver scrolls elements
into view automatically before clicking them.

On Mon, 4 Dec 2017 at 13:46, <[email protected]> wrote:

> waitFor or sleep does not help me there.
>
> only clicking buttons like this:
>
> WebElement element = driver.findElement(By.xpath(xpath));
> JavascriptExecutor executor = (JavascriptExecutor) driver;
> executor.executeScript("arguments[0].click()", element)
>
>
> any other idea why elements are not clickable?
>
> should I scroll the element to view? is this possible in geb?
>
> sometimes the error message says "cannot focus on element".
>
> thank you,
> Roland
>
> On Thursday, November 30, 2017 at 4:41:13 PM UTC+1, brian428 wrote:
>
>> Most likely the element is animated somehow, so its position is changing.
>> You need to wait for it to stop changing position before you try to trigger
>> a click on it.
>>
> On Thu, Nov 30, 2017 at 6:43 AM, <[email protected]> wrote:
>>
> hi,
>>>
>>> I keep getting this error more and more:
>>>
>>> org.openqa.selenium.WebDriverException: unknown error: Element is not
>>> clickable at point (805, 1183)
>>>       (Session info: chrome=62.0.3202.94)
>>>       (Driver info: chromedriver=2.27.440175 (
>>> 9bc1d90b8bfa4dd181fbbf769a5eb5e575574320),platform=Linux 3.16.0-4-amd64
>>> x86_64) (WARNING: The server did not provide any stacktrace information)
>>>
>>> Is there any solution to prevent it or any workaround?
>>>
>>> Thank you,
>>> Roland
>>>
>>>
>>> --
>>> You received this message because you are subscribed to the Google
>>> Groups "Geb User Mailing List" group.
>>>
>> To unsubscribe from this group and stop receiving emails from it, send an
>>> email to [email protected].
>>> To post to this group, send email to [email protected].
>>
>>
>>> To view this discussion on the web visit
>>> https://groups.google.com/d/msgid/geb-user/12461655-78e9-47a1-912b-f9acc1e7b9f0%40googlegroups.com
>>> <https://groups.google.com/d/msgid/geb-user/12461655-78e9-47a1-912b-f9acc1e7b9f0%40googlegroups.com?utm_medium=email&utm_source=footer>
>>> .
>>> For more options, visit https://groups.google.com/d/optout.
>>>
>> --
> You received this message because you are subscribed to the Google Groups
> "Geb User Mailing List" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to [email protected].
> To post to this group, send email to [email protected].
> To view this discussion on the web visit
> https://groups.google.com/d/msgid/geb-user/827e110a-435e-47f1-9937-b43d948aeca8%40googlegroups.com
> <https://groups.google.com/d/msgid/geb-user/827e110a-435e-47f1-9937-b43d948aeca8%40googlegroups.com?utm_medium=email&utm_source=footer>
> .
> For more options, visit https://groups.google.com/d/optout.
>

-- 
You received this message because you are subscribed to the Google Groups "Geb 
User Mailing List" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit 
https://groups.google.com/d/msgid/geb-user/CA%2B52dQQ_E8vAs%3DCwhrnCWUzg0M4PKDAuUDYZFBx5Zq36TfQygg%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

Reply via email to