public void Execute() {
using (var automation = new UIA3Automation())
{
using (var app = FlaUI.Core.Application.Launch(PRCDFileLocation))
{
log.InfoFormat("Launch {0}", PRCDFileLocation);
Window window = app.GetMainWindow(automation, TimeSpan.FromSeconds(5000));
//FlaUI.Core.Input.Wait.UntilResponsive(window.FindFirstChild(), TimeSpan.FromSeconds(5000));
if (window != null)
log.InfoFormat("Main Window {0} is found", PRCDFileLocation);
log.WarnFormat("Configuration Menu {0} is not found", PRCDFileLocation);
if (EnablePIOScript)
StartupLoadPio(window);
if (EnableEventScript)
StartLoadEvent(window);
}
}
}
if i run the program , the application launches but the program is not moving forward , i added thread.sleep not working , once the launch method is initiated , the application takes time to open so i added timespan.fromseconds . but after the application is launched StartupLoadPio should be executed but the application is not running automatically as expected . there is log attached to the program