UiPath利用Open browser组件打开IE浏览器时报错,而chrome及Firefox却正常
报错信息如下:
Message: Cannot communicate with Internet Explorer browser.
Source: Open browser
Exception Type: BrowserOperationException
UiPath.Core.BrowserOperationException: Cannot communicate with Internet Explorer browser. —> System.Runtime.InteropServices.COMException: Cannot communicate with Internet Explorer browser.
at UiPath.UiBrowserClass.Open(String bstrURL, UiBrowserFlags flag)
at UiPath.Core.Browser.Open(String url, Boolean privateSession, Boolean headlessSession, Boolean defaultSession)
— End of inner exception stack trace —
at UiPath.Core.Activities.ScopeActivity.EndExecute(NativeActivityContext context, IAsyncResult result)
at UiPath.Core.Activities.AsyncNativeActivity.BookmarkResumptionCallback(NativeActivityContext context, Bookmark bookmark, Object value)
at System.Activities.Runtime.BookmarkCallbackWrapper.Invoke(NativeActivityContext context, Bookmark bookmark, Object value)
at System.Activities.Runtime.BookmarkWorkItem.Execute(ActivityExecutor executor, BookmarkManager bookmarkManager)
解决办法:
1、管理员身份打开cmd.exe ,然后输入regsvr32.exe oleacc.dll
2、如果依然报错,需要设置IE Internet选项里面的安全,需要设置自定义级别,将下面的脚本项下的所有项设置为启用
之后重启计算机,然后重新运行流程文件即可打开IE浏览器
解决方法源自:https://www.uipath.com/kb-articles/internet-explorer-automation-troubleshooting