Clicking on an element in robot framework is not working in IE, but its working fine in Chrome & Firefox

0 votes

Clicking on the Element is not working in Robot Framework. In the log.html, it shows that it clicked on the element, but it does not actually happen in the browser.

The element which I want to click is:

<a href="http://www.twitter.com/intent/tweet?text=Orange%20named%20a%20Top%20Employer%20Global%202018%20for%203rd%20consecutive%20year&amp;url=http%3A%2F%2Fintegration-ruby.proj.620nm.com%2Fen%2Fblogs%2Forange-named-top-employer-global-2018-3rd-consecutive-year&amp;via=orangebusiness" class="share-button-twitter" target="_blank" title="Share on twitter">
        <span class="fa-lg fa-stack text_black"> <i class="fa fa-circle-thin fa-stack-2x"></i> <i class="fa fa-twitter fa-stack-1x"></i> </span>
    </a>

I run my test using:

Execute JavaScript    document.querySelector(".share-button-twitter").click()
Execute JavaScript    document.querySelector('a[title="Share on twitter"]').click()
Execute JavaScript    document.querySelector(".fa-lg fa-stack text_black").click()
Click Link  //a[@title="Share on twitter"]
Click Element    //i[@class="fa fa-twitter fa-stack-1x"]
Click Element    //span[@class="fa-lg fa-stack text_black"]

The element is visible in the page, and the script works fine in Chrome and Firefox I find this essue with the browser IE.

What can be the reason for this? Any idea to solve the problem?

Mar 30, 2018 in Selenium by Shubham
• 13,290 points
1,921 views

2 answers to this question.

0 votes
The only solution to this problem is: Update your Internet Explorer to the latest version. Also download the appropriate supported version of IEDriver for that version of IE. The problem is only here, and no where else. Nothing is wrong with the code and that is evident from the execution on Chrome & Firefox.
answered Mar 30, 2018 by nsv999
• 5,090 points
0 votes
Hello,

i have the same problem , did u find the solution ?

thanks.
answered Jun 14 by Miya

Hi Miya, I got a workaround for this kind of problems, as suggested by @nsv999 I updated my IE browser to the latest version. Also I used thread.sleep() and webdriver.wait() methods to let the elements load properly before performing actions on them like click element.

Related Questions In Selenium

0 votes
1 answer

Xpath not working in firefox but working fine in chrome

Try to search above xpath in chrome ...READ MORE

answered Jul 17, 2018 in Selenium by Samarpit
• 5,130 points
731 views
0 votes
0 answers

How to hover element when action class is not working in my Selenium framework ?

When i am writing the code to ...READ MORE

Feb 15 in Selenium by Raishul
345 views
0 votes
1 answer
0 votes
1 answer
0 votes
1 answer

Installing Selenium Webdriver with Python package

Hey Hemant, for installing Selenium Webdriver with ...READ MORE

answered May 8 in Selenium by Anvi
• 12,860 points
146 views
0 votes
1 answer

Confused betwen Java AWT Robot & Selenium Actions

There are plenty of differences between the ...READ MORE

answered Apr 6, 2018 in Selenium by nsv999
• 5,090 points
1,186 views
0 votes
1 answer

Finding WebDriver element with Class Name in java

The better way to handle this element ...READ MORE

answered Apr 10, 2018 in Selenium by nsv999
• 5,090 points
592 views
0 votes
1 answer
0 votes
2 answers

Unable to Click on an Element in Selenium (Python) even after finding it.

Here, I give you working script which ...READ MORE

answered Sep 19, 2018 in Selenium by Priyaj
• 56,540 points
7,434 views