Wednesday, January 22, 2020

How to Launch Excel With WinAppDriver No Splash Screen & Open File

In this video I show you how to Launch Microsoft Excel using WinAppDriver.
If you have only one version of Excel installed on your machine, you don't need to provide full application path to Excel.
I also show you how to add Appium to your solution, using Nuget package manager.
Please note that I am using .Net framework 4.5.

We will use objects of WindowsDriver<WindowsElement> and AppiumOptions classes.
I'll call the method AddAdditionalCapability on the AppiumOptions object.
Once Excel is started in normal mode, I go on demonstrate in this video the C# code to specify "appArguments" and run Excel without showing splash screen.

The last thing this video shows is how to launch Excel and load a file by default using Appium WinAppDriver. This technique can save a lot of UI automation steps if you need to open Excel with a specific file.
I needed to open an Excel file saved on the disk in order to test an Excel Add In using Appium WinAppDriver. I used the technique shown in this video to open a file without a single extra click at the test/automation execution time.

Appium WinAppDriver: Automated UI Testing Windows Apps in C#

1 comment:

  1. Hello Sir,
    I've tried your solution and it works great
    I also tried you solution to get cells value (all sheets in tables)
    But I'm not able to find value and name of RadioButton on the worksheet without clicking on it when Excel opens
    Do you know any solution to find all radiobuttons name and value of a worksheet without clicking on it ?
    Thanks in adavance


Feel free to talk back...