0

I'm Trying to launch url in Edge with IE compatibility mode using robotframe work python and I'm using below code but getting this error AttributeError: 'Options' object has no attribute 'attach_to_edge_chrome' . Can some please help on this

code used:

Open Browser url ie options=ignore_zoom_level=True;attach_to_edge_chrome=True; edge_executable_path="C:\Program Files (x86)\Microsoft\Edge\Application\msedge.exe"

6
  • What version of edge? What OS? Starting June 15, 2022, Internet Explorer 11 will no longer be supported on certain versions of Windows 10. Commented Oct 13, 2022 at 17:34
  • Is there any particular reason you have to be attached to Edge? You might find greater success in using Firefox Commented Oct 13, 2022 at 19:23
  • I test your code and it works well. Which version of robotframework and SeleniumLibrary are you using? Which version of IE WebDriver, Edge browser and Edge WebDriver are you using? Commented Oct 14, 2022 at 10:14
  • Im using these versions @YuZhou -------robot framework-4.1.3, selenium-4.0.0, robotframework-seleniumlibrary 4.5.0, IEdriver 4.5.0, Edge browser-106.0, Commented Oct 14, 2022 at 14:32
  • I use the latest version robotframework 5.0.1 and SeleniumLibrary 6.0.0. Please update to the latest version and test again. Commented Oct 17, 2022 at 2:56

1 Answer 1

0

You could use Maximize Browser Window to maximize the browser window. Please refer to the sample code below (you can change the path to your owns):

*** Settings ***
Library   SeleniumLibrary

*** Variables ***
${IEDriver}  E:/webdriver/IEDriverServer.exe

*** Test Cases ***
Example Test
    Open Browser  https://www.google.com/  ie  executable_path=${IEDriver}  options=ignore_zoom_level=True; attach_to_edge_chrome=True; edge_executable_path="C:\\Program Files (x86)\\Microsoft\\Edge\\Application\\msedge.exe"
    Maximize Browser Window

Robot Framework version: 5.0.1

SeleniumLibrary version: 6.0.0

Sign up to request clarification or add additional context in comments.

9 Comments

im using what you have mentioned but only Open Browser is keep on running, it is not going to the next keyword :(
Is there any error? Please try to kill all Edge and IE process in Task Manager and test again. Besides, I met similar issue when I missed some spaces in the line of Open Browser code. Please check again if the spaces between the codes are right, especially there's a space between options=ignore_zoom_level=True; and attach_to_edge_chrome=True;
Open Browser google.com ie executable_path=${Iedriver} options=ignore_zoom_level=True; attach_to_edge_chrome=True; edge_executable_path=${edgepath} Close Window ------------ not getting any error . Google URL is opening in edge IE mode and after that nothing is happening, it is not going to the next step in the code . And Im giving the proper spaces also.
I guess Complete page is not loading properly after long time im getting time out exception for page load.
It might be the reason. It's so strange it doesn't work in your environment. You can check my result, it works well: i.sstatic.net/7DgQI.gif. How about change to another url? And do you have another environment to test?
|

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.