How do I do this in NetBeans?
Main Topics
Browse All TopicsHi,
I'm writing a Java program and when I call a method that is included in a jar library, I get the following error:
Exception in thread "AWT-EventQueue-0" java.lang.UnsatisfiedLinkE
Any idea on what this error means?
Thanks!
This Question has been solved and asker verified All Experts Exchange premium technology solutions are available to subscription members.
Experts Exchange has been collecting answers to technology questions since 1996…3 million and counting! If you have a question, chances are we already have your answer.
If you can't find the exact answer you're looking for, ask our exclusive community of 50,000 experts. You’ll get a personalized answer from a trusted professional.
Thousands of free tech tips, tricks, how-to’s and tutorials are available in our peer reviewed articles section. See for yourself how smart our experts are, no login required.
Access the answers to your technology questions today.
30-day free trial. Register in 60 seconds.
Members of the expert community talk about why the experience at Experts Exchange is different than what you will find anywhere else.

Try it out and discover for yourself.
30-day free trial. Register in 60 seconds.
Join the community of experts here and help other tech pros by answering question in your area of expertise. You can earn FREE access to all Experts Exchange's premium features and resources.
cmalaker, the setProperty method does not work. The default classloader won't notice changes in the java.library.path property. The -D option does work obviously. You could also put the library in the default windows path. Either add a folder to the windows path to store the library, or in extreme cases put the .dll in the windows folder or the bin folder of your Java runtime.
In netbeans, you should be able to pass the -Djava.library.path to the JVM. The property should be set to the path *excluding* the name of the file itself. The file itself should be called <libraryname>.dll (assuming windows) or <libraryname>.so in Linux. I presume you have found the .dll, can you explain what exact options you have tried?
Optionally, the library could also be loaded using the full path to the library from the .jar. In this case you will have to see the documentation of whoever supplied the jar library to you.
"That worked!!! Why did I have to reference a .dll file? I thought that Java doesn't use DLLs?"
Java may use libraries to do native (as in "native to the operating system"). Without an interface to the operating system, there is very little Java can do. It would not be able to read files, create network sockets, create windows etc. etc. . Of course, the base JVM will make sure that the most common options like the ones I've mentioned are present for all platforms. For new platforms, this functionality will have to be provided.
That still leaves an awful lot of functionality that is not directly available within the Java runtime. Much of it you will never need, or can be recreated in the Java language itself. But if you want to access OS functionality (i.e. drivers) or CPU functionality (i.e. SSE "multimedia" instructions) directly, you will still need native code. This native code can be supplied in JNI compatible .dll's. This is what you are currently configuring.
Business Accounts
Answer for Membership
by: cmalakarPosted on 2008-09-30 at 10:25:32ID: 22607526
>> java.lang.UnsatisfiedLinkE rror: no nitf.jni-c in java.library.path
YourLibrar y ProgramName
Means a library file is missing the java library path.. If you know.. the library..
then add the library to the java.library.path as follows.. when you start the java program.
java -Djava.library.path=PathTo