I am opening an excel file lets call it "ABC" file from a specific folder location , then clicking on file , save as adobe pdf, then clicking on convert to pdf and saving it. after that I the excel file - "ABC" is still open. So i used the same excel instance that i used while opening it and gave the command close excel. Its throwing an error saying cannot close, I tried closing with send keys as well it still doesnt close. Can someone please help with this?
please find the error details as below:
Correlation Id: 3b0d2e9e-b99c-4db0-94b1-c76ad4972a54
The object invoked has disconnected from its clients. (Exception from HRESULT: 0x80010108 (RPC_E_DISCONNECTED)): Microsoft.PowerPlatform.PowerAutomate.Desktop.Actions.SDK.ActionException: Failed to close Excel instance. ---> System.Runtime.InteropServices.COMException: The object invoked has disconnected from its clients. (Exception from HRESULT: 0x80010108 (RPC_E_DISCONNECTED))
at System.RuntimeType.InvokeDispMethod(String name, BindingFlags invokeAttr, Object target, Object[] args, Boolean[] byrefModifiers, Int32 culture, String[] namedParameters)
at System.RuntimeType.InvokeMember(String name, BindingFlags bindingFlags, Binder binder, Object target, Object[] providedArgs, ParameterModifier[] modifiers, CultureInfo culture, String[] namedParams)
at System.Type.InvokeMember(String name, BindingFlags invokeAttr, Binder binder, Object target, Object[] args, CultureInfo culture)
at Microsoft.Flow.RPA.Desktop.Modules.Excel.Actions.ExcelActions.InvokeMethod(Object o, String methodName, Object[] methodArgs)
at Microsoft.Flow.RPA.Desktop.Modules.Excel.Actions.ExcelActions.CloseExcel(Variant excelInstance, Variant documentPath, Int32 save, Int32 saveAsFormat, String xmlMapName)
--- End of inner exception stack trace ---
at Microsoft.Flow.RPA.Desktop.Modules.Excel.Actions.CloseExcel.Execute(ActionContext context)
at Microsoft.Flow.RPA.Desktop.Robin.Engine.Execution.ActionRunner.Run(IActionStatement statement, Dictionary`2 inputArguments, Dictionary`2 outputArguments)