Inject Js Script: Error HRESULT E_FAIL has been returned from a call to a COM component

Hi guys,

Issue description:
use InjectJS active and do some string options in Chrome, but I got this error message:
Inject Js Script: Error HRESULT E_FAIL has been returned from a call to a COM component.

If someone can help to solve this issue?

Many thanks~

Kindly kill the processes that you are using in your code before starting the robot actual process in code. It will solve your issue.

For Testing, Manually kill the chrome, excel, etc (Softwares robot may use) then run the bot and check.

Error HRESULT E_FAIL - It is because of other processes using the software that you are trying to use via robot

Hi [ranjith_udayakumar],

Thanks for reply, because Inject JS must give it a broswer element, so I can’t kill all chrome process because Inject JS active needed.
My issue reproduce steps inbelow:

  1. open Chrome with only one tab
  2. run script-> Inject JS
  3. error message occured after a little while

Latest update

  1. downgrade the dependence Uipath.UIAutomation.Activites from 19.11.0 to 19.10.1, refer below for details
    dependenciesVersion
  2. remove attach browser , use open browser with inject js
  3. give a selector to Inject JS active

followed above steps , this issue not reproduce again. But for my business logic , I need to use attach browser active.