R
Rachel
Hi,
I have 2 jar files (packageA.jar & packageB.jar) + 1 DLL (used by
packageB.jar) in the follow hierarchy:
folder1/app/packageA.jar (with main-class packA.classA)
folder1/app/dllC.DLL
folder1/lib/packageB.jar (classes packaged in packB)
folder1/app/run.bat has the following:
java -Djava.library.path=. -classpath
...;.;../lib/packageB.jar;../app/packageA.jar packA.classA
1. When folder 1 is located in a local drive, the program runs successfully.
2. But when folder1 is located in a network drive, I get the following
ERROR:
Z:\folder1\app>java -Djava.library.path=. -classpath
...;.;../lib/packageB.jar;../app/packageA.jar packA.classA
java.lang.UnsatisfiedLinkError: Z:\folder1\app\dllC.DLL: Access is denied:
Check that native library dllC is in proper directory
Exception in thread "main" java.lang.UnsatisfiedLinkError: GetVoice
at packB.Voice.GetVoice(Native Method)
at packB.Voice.GetVoiceList(VoiceLocal.java:1003)
at packA.Display.<init>(DisplayApp.java:31)
at packA.Display.main(DisplayApp.java:60)
3. Then I changing my run.bat to the following & ran from Z and it WORKS!:
Z:\folder1\app>java -Djava.library.path="C:/folder1/app" -classpath
...;.;../lib/packageB.jar;../app/packageA.jar packA.classA
Why is it so that my application fails to run when I try to invoke it from
Z? Is it because DLLs cannot be loaded from network drives? Why does it say
Access is denied? Is there some permission that I need to set on Z drive?
Thanks much,
Rach
I have 2 jar files (packageA.jar & packageB.jar) + 1 DLL (used by
packageB.jar) in the follow hierarchy:
folder1/app/packageA.jar (with main-class packA.classA)
folder1/app/dllC.DLL
folder1/lib/packageB.jar (classes packaged in packB)
folder1/app/run.bat has the following:
java -Djava.library.path=. -classpath
...;.;../lib/packageB.jar;../app/packageA.jar packA.classA
1. When folder 1 is located in a local drive, the program runs successfully.
2. But when folder1 is located in a network drive, I get the following
ERROR:
Z:\folder1\app>java -Djava.library.path=. -classpath
...;.;../lib/packageB.jar;../app/packageA.jar packA.classA
java.lang.UnsatisfiedLinkError: Z:\folder1\app\dllC.DLL: Access is denied:
Check that native library dllC is in proper directory
Exception in thread "main" java.lang.UnsatisfiedLinkError: GetVoice
at packB.Voice.GetVoice(Native Method)
at packB.Voice.GetVoiceList(VoiceLocal.java:1003)
at packA.Display.<init>(DisplayApp.java:31)
at packA.Display.main(DisplayApp.java:60)
3. Then I changing my run.bat to the following & ran from Z and it WORKS!:
Z:\folder1\app>java -Djava.library.path="C:/folder1/app" -classpath
...;.;../lib/packageB.jar;../app/packageA.jar packA.classA
Why is it so that my application fails to run when I try to invoke it from
Z? Is it because DLLs cannot be loaded from network drives? Why does it say
Access is denied? Is there some permission that I need to set on Z drive?
Thanks much,
Rach