Object Spy to click button in Excel


I have a test case where I need to copy data in excel file into another excel sheet. Later, I need to click on the button inside the excel sheet. This button is not provided by excel but created by engineer with function.

Please help me on how to object spy that button in order for me to be able to click on it when I open the excel during running time. Or if you have any suggestion of what should I be doing, please help…

I tried using Spy Window Object, but it seems an error occured : image

Below is the screenshot of the button that I mentioned in above :

If I click on it , the data will be generated from column A to N

Hi @FieSabil13,

According to the error message you provided. It said that the Excel app didn’t start successfully /=). So maybe you could follow this instruction to prepare the appropriate environment for desktop testing.

Hi @thongnmtran,

I guess that’s actually the main issue !
Following the step provided and keep WinAppDriver open during test execution, now I am able to do some action in excel or excel macro. Thank you

1 Like

~ Happy testing! :smiley: :+1:

1 Like