← Back to team overview

sikuli-driver team mailing list archive

Re: [Question #268573]: Java API - FindFailed: can not find image on second monitor

 

Question #268573 on Sikuli changed:
https://answers.launchpad.net/sikuli/+question/268573

    Status: Answered => Open

Maks is still having a problem:
RaiMan, thanks for your answer. But this only works for default monitor.
When I start program for default monitor, square with a red border
appear in center. But for second monitor - square with a red border
appeared in center filled in black colour inside.

          The output for default monitor (success):

"C:\Program Files (x86)\Java\jdk1.7.0_79\bin\javaw.exe" -client -classpath "C:\jdeveloper\mywork\Sikuli\.adf;C:\jdeveloper\mywork\Sikuli\Sikuli\classes;C:\Sikuli\Sikuli 1.1.0\sikulixapi.jar" -Dhttp.proxyHost=proxy.mfbmain.internal -Dhttp.proxyPort=3128 -Dhttp.nonProxyHosts=*.mfbmain.internal;ibank.procreditbank.com.ua;webmail.procreditbank.com.ua;probanking.procreditbank.com.ua;*.internal.procreditbank.com.ua;10.*;172.*;192.168.*;<local>|localhost|localhost.localdomain|127.0.0.1|::1|hof83pc11.mfbmain.internal|hof83pc11|10.2.5.72|[::1]|HOF83PC11.mfbmain.internal|HOF83PC11 -Dhttps.proxyHost=proxy.mfbmain.internal -Dhttps.proxyPort=3128 sikuli.Sikuli
[debug] Debug.init: from sikuli.Debug: on: 3
[debug] RunTimeINIT: loadOptions: check: C:\jdeveloper\mywork\Sikuli\Sikuli
[debug] RunTimeINIT: loadOptions: check: C:\Users\%USERNAME%
[debug] RunTimeINIT: loadOptions: check: C:\Users\%USERNAME%\AppData\Roaming\Sikulix\SikulixStore
[debug] RunTimeINIT: global init: entering as: API
[debug] RunTimeINIT: ScreenDevice 0 contains (0,0) --- will be used as primary
[debug] RunTimeINIT: fSxBase: C:\Sikuli\Sikuli 1.1.0
[debug] RunTimeINIT: runs as sikulixapi.jar in: C:\Sikuli\Sikuli 1.1.0
[debug] RunTimeINIT: exists libs folder at: C:\Users\%USERNAME%\AppData\Roaming\Sikulix\SikulixLibs_201504200100
[debug] RunTimeINIT: addToWindowsSystemPath: added to systempath:
C:\Users%USERNAME%\AppData\Roaming\Sikulix\SikulixLibs_201504200100
[debug] RunTimeINIT: checkJavaUsrPath: added to ClassLoader.usrPaths
[debug] FileManager: xcopy from: C:\Program Files (x86)\Java\jdk1.7.0_79\jre\bin\jawt.dll
to: C:\Users%USERNAME%\AppData\Roaming\Sikulix\SikulixLibs_201504200100\jawt.dll
java.io.FileNotFoundException: C:\Users\%USERNAME%\AppData\Roaming\Sikulix\SikulixLibs_201504200100\jawt.dll (Процесс не может получить доступ к файлу, так как этот файл занят другим процессом)
***** show environment for API (build 201504200100)
user.home: C:\Users\%USERNAME%
user.dir (work dir): C:\jdeveloper\mywork\Sikuli\Sikuli
user.name: %USERNAME%
java.io.tmpdir: C:\Users\%USERNAME%~1\AppData\Local\Temp
running 32Bit on Windows (6.1) from a jar
java 7-32 version 1.7.0_79-b15 vm 24.79-b02 class 51.0 arch x86
app data folder: C:\Users\%USERNAME%\AppData\Roaming\Sikulix
libs folder: C:\Users\%USERNAME%\AppData\Roaming\Sikulix\SikulixLibs_201504200100
executing jar: C:\Sikuli\Sikuli 1.1.0\sikulixapi.jar
*** classpath dump sikulix
  2: /C:/Sikuli/Sikuli%201.1.0/sikulixapi.jar
*** classpath dump end
***** show environment end
[debug] RunTimeAPI: global init: leaving
[debug] RunTimeAPI: loadLib: VisionProxy.dll
[debug] Mouse: init
[debug] KeyBoard: init
[debug] Screen: initScreens: multi monitor mouse check
[debug] Screen: *** checking: S(0)[0,0 1280x1024] center: (640, 512) --- OK
[debug] Screen: *** checking: S(1)[-1280,0 1280x1024] center: (-640, 512) --- OK
[log] highlight R[590,462 100x100]@S(0)[0,0 1280x1024] E:Y, T:3,0 for 2.0 secs
[log] highlight M[182,291 7x7]@S(S(0)[0,0 1280x1024]) S:1,00 C:185,294 [310/270 msec] for 2.0 secs
Process exited with exit code 0.

          The output for second monitor (failed):
"C:\Program Files (x86)\Java\jdk1.7.0_79\bin\javaw.exe" -client -classpath "C:\jdeveloper\mywork\Sikuli\.adf;C:\jdeveloper\mywork\Sikuli\Sikuli\classes;C:\Sikuli\Sikuli 1.1.0\sikulixapi.jar" -Dhttp.proxyHost=proxy.mfbmain.internal -Dhttp.proxyPort=3128 -Dhttp.nonProxyHosts=*.mfbmain.internal;ibank.procreditbank.com.ua;webmail.procreditbank.com.ua;probanking.procreditbank.com.ua;*.internal.procreditbank.com.ua;10.*;172.*;192.168.*;<local>|localhost|localhost.localdomain|127.0.0.1|::1|hof83pc11.mfbmain.internal|hof83pc11|10.2.5.72|[::1]|HOF83PC11.mfbmain.internal|HOF83PC11 -Dhttps.proxyHost=proxy.mfbmain.internal -Dhttps.proxyPort=3128 sikuli.Sikuli
[debug] Debug.init: from sikuli.Debug: on: 3
[debug] RunTimeINIT: loadOptions: check: C:\jdeveloper\mywork\Sikuli\Sikuli
[debug] RunTimeINIT: loadOptions: check: C:\Users\%USERNAME%
[debug] RunTimeINIT: loadOptions: check: C:\Users\%USERNAME%\AppData\Roaming\Sikulix\SikulixStore
[debug] RunTimeINIT: global init: entering as: API
[debug] RunTimeINIT: ScreenDevice 0 contains (0,0) --- will be used as primary
[debug] RunTimeINIT: fSxBase: C:\Sikuli\Sikuli 1.1.0
[debug] RunTimeINIT: runs as sikulixapi.jar in: C:\Sikuli\Sikuli 1.1.0
[debug] RunTimeINIT: exists libs folder at: C:\Users\%USERNAME%\AppData\Roaming\Sikulix\SikulixLibs_201504200100
[debug] RunTimeINIT: addToWindowsSystemPath: added to systempath:
C:\Users\%USERNAME%\AppData\Roaming\Sikulix\SikulixLibs_201504200100
[debug] RunTimeINIT: checkJavaUsrPath: added to ClassLoader.usrPaths
[debug] FileManager: xcopy from: C:\Program Files (x86)\Java\jdk1.7.0_79\jre\bin\jawt.dll
to: C:\Users\%USERNAME%\AppData\Roaming\Sikulix\SikulixLibs_201504200100\jawt.dll
java.io.FileNotFoundException: C:\Users\%USERNAME%\AppData\Roaming\Sikulix\SikulixLibs_201504200100\jawt.dll (Процесс не может получить доступ к файлу, так как этот файл занят другим процессом)
***** show environment for API (build 201504200100)
user.home: C:\Users\%USERNAME%
user.dir (work dir): C:\jdeveloper\mywork\Sikuli\Sikuli
user.name: %USERNAME%
java.io.tmpdir: C:\Users\VORCHU~1\AppData\Local\Temp
running 32Bit on Windows (6.1) from a jar
java 7-32 version 1.7.0_79-b15 vm 24.79-b02 class 51.0 arch x86
app data folder: C:\Users\%USERNAME%\AppData\Roaming\Sikulix
libs folder: C:\Users\%USERNAME%\AppData\Roaming\Sikulix\SikulixLibs_201504200100
executing jar: C:\Sikuli\Sikuli 1.1.0\sikulixapi.jar
*** classpath dump sikulix
  2: /C:/Sikuli/Sikuli%201.1.0/sikulixapi.jar
*** classpath dump end
***** show environment end
[debug] RunTimeAPI: global init: leaving
[debug] RunTimeAPI: loadLib: VisionProxy.dll
[debug] Mouse: init
[debug] KeyBoard: init
[debug] Screen: initScreens: multi monitor mouse check
[debug] Screen: *** checking: S(0)[0,0 1280x1024] center: (640, 512) --- OK
[debug] Screen: *** checking: S(1)[-1280,0 1280x1024] center: (-640, 512) --- OK
[log] highlight R[-690,462 100x100]@S(1)[-1280,0 1280x1024] E:Y, T:3,0 for 2.0 secs
Exception in thread "main" FindFailed: can not find plus.png in S(1)[-1280,0 1280x1024]
  Line 2151, in file Region.java

	at org.sikuli.script.Region.handleFindFailedShowDialog(Region.java:2151)
	at org.sikuli.script.Region.handleFindFailed(Region.java:2096)
	at org.sikuli.script.Region.wait(Region.java:2298)
	at org.sikuli.script.Region.find(Region.java:2167)
	at sikuli.Sikuli.main(Sikuli.java:17)
Process exited with exit code 1.

Thanks for your help.

-- 
You received this question notification because you are a member of
Sikuli Drivers, which is an answer contact for Sikuli.