LeanFT Error trying to launch Flights GUI demo

Question ID: 109126
1
0

I’m using Visual Studio. Getting a NullReferenceException error when trying to launch the Flights GUI demo application from LeanFT. Here’s the code I’m trying to use:

IAut FlightsApp = Desktop.LaunchAut("C:\\\\Training\\\\Flights Application\\\\FlightsGUI.exe");

Marked as spam
Posted by (Questions: 328, Answers: 10)
Asked on July 30, 2019 3:47 pm
5 views
Answers
0
Private answer

Try this code instead:

//Remember to include this 'using' statement
using System.Diagnostics;

//in your test method:
Process appProcess = new Process { StartInfo = { FileName = @''C:UsersAdministratorDesktopFlights ApplicationFlightsGUI.exe'' } };
appProcess.Start();

Marked as spam
Posted by (Questions: 16, Answers: 738)
Answered on July 30, 2019 3:47 pm
Awesome! That code worked perfectly! Thank you!!
( at July 30, 2019 3:48 pm)