sikuli-driver team mailing list archive
-
sikuli-driver team
-
Mailing list archive
-
Message #32479
Re: [Question #267140]: App.open() open exe file twice on windows 7. How to launch only one instance?
Question #267140 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/267140
Status: Open => Answered
RaiMan proposed the following answer:
this works on Win 7 for me:
String pgmPath = "\"C:\\Program Files\\Microsoft Games\\Minesweeper\\MineSweeper.exe\"";
App pgm = new App(pgmPath);
pgm.open();
RunTime.pause(2);
pgm.focus();
Take care:
The program path has to obey the rules how it has to be specified on command line, which in this case means, that I have to add extra apostrophes before and after (need to be escaped of course), because the path contains blanks.
--
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.