Error in click operation inside attach window while doing background automation

Hi All

I have an excel file where i am doing some manipulation. I am selecting a range and typing Alt+h+o+e to open the Format Cell window. Then doing attach window and then clicking the Font tab. I am using Simulate Click while clicking. The excel files are not visible while working. I have unchecked the Visible property in Excel Application Scope.

So now the click on the Font tab in the window is throwing error “Selector Not Found”. But its highlighting properly when i am checking the selector. Can anyone tell me what could be the reason ?

@kkpatel You need to Enable Visibility in order for it to Open the Excel Window and find the selector :sweat_smile:

Ok, but then how can i automate it to work in the background ? Let say when i deploy this in production how would it work as an unattended robot ?

@kkpatel Can you tell me what are you trying to do, it might as well be performed in Background using some other methods :sweat_smile:

Ok. I have to select a range in the excel and open the format cell window and click on font tab and click on the checkbox Normal Font.

@kkpatel Ok that is a Bit Complicated to Achieve :sweat_smile: , But I guess it is possible using Macros.

Ok then where can we do background automation and where not ? And what is the reason in my case the background automation is not working?

@kkpatel The Background Automation doesn’t work in your case, Since you have unchecked the Visibility. For a Selector to Work it Shoud Find the UiElement needed, But Since the Application is Closed, No Excel Window is Available, Hence the Automation fails.

Well in that case any ui automation like web page login process and any operation in the website won’t work in the background. So it can never be an unattended robot.

@kkpatel For the Web page Login Process, The web page will be open but It need not be in the foreground. Using Send Windows Messages the Background Login process can be done.

Ok, so similarly why its not happening here in my case?

Could you please explain why the same is not happening in my case here ?

@kkpatel It doesn’t happen because the Excel Window is not being opened :sweat_smile:, Also You can try using the Start Process Activity , Providing the Path of Excel Application exe File. Then pass your Excel File path as argument.

Then you might be able to perform the operations in the Background.