Results 1 to 1 of 1
- 11-19-2010, 11:59 PM #1
Member
- Join Date
- Nov 2010
- Posts
- 13
- Rep Power
- 0
JNI: ava.lang.UnsatisfiedLinkError
Ok I keep getting this error when i run my code. I tried taking out the line of code to execute the function and the program worked with no error, so I know that is causing the problem, but I can't figure out how to fix it.
I would greatly appreciate some help.
Exact Error Message
Java Code:java.lang.UnsatisfiedLinkError: exe.MouseMotionExample$DLLfunz.RunExe()V at exe.MouseMotionExample$DLLfunz.RunExe(Native Method) at exe.MouseMotionExample.openc(MouseMotionExample.java:80) at exe.MouseMotionExample.init(MouseMotionExample.java:45) at sun.applet.AppletPanel.run(AppletPanel.java:424) at java.lang.Thread.run(Thread.java:619)
Main.java
Java Code:class DLLfunz {public native void RunExe(); public void load() { System.load("C:\\Users\\Trent\\Documents\\NetBeansProjects\\eRunDLL\\dist\\Release\\Cygwin-Windows\\libeRunDLL.dll"); System.out.println("Hello");} } public void openc() {DLLfunz go=new DLLfunz(); go.load(); go.RunExe(); System.out.println("Hello"); }
main.cpp
Java Code:#include <windows.h> #include "DLLfunz.h" #include <iostream> #include <stdlib.h> #include <string> #include <wincon.h> JNIEXPORT void JNICALL Java_DLLfunz_RunExe(JNIEnv *, jobject) {WinExec("c:/test.exe",3); HWND windowvar=FindWindow(NULL,"Anti-Decompiler");}
DLLfunz.h
Java Code:/* DO NOT EDIT THIS FILE - it is machine generated */ #include "jni.h" /* Header for class DLLfunz */ #ifndef _Included_DLLfunz #define _Included_DLLfunz #ifdef __cplusplus extern "C" { #endif /* * Class: DLLfunz * Method: RunExe * Signature: ()V */ JNIEXPORT void JNICALL Java_DLLfunz_RunExe (JNIEnv *, jobject); #ifdef __cplusplus } #endif #endif
Similar Threads
-
java.lang.UnsatisfiedLinkError: mqjbnd05
By sasi25 in forum Advanced JavaReplies: 1Last Post: 12-30-2009, 04:48 PM -
java.lang.UnsatisfiedLinkerror: no swt-carbon-3449 or ....
By cristo_haris in forum Advanced JavaReplies: 3Last Post: 04-24-2009, 10:23 AM -
java.lang.UnsatisfiedLinkerror: no swt-carbon-3449 or ....
By cristo_haris in forum EclipseReplies: 0Last Post: 04-23-2009, 08:17 AM -
java.lang.UnsatisfiedLinkError
By sunil.mact in forum Advanced JavaReplies: 4Last Post: 03-03-2009, 05:36 PM -
java.lang.UnsatisfiedLinkError: JAWT_GetAWT()
By Albert in forum AWT / SwingReplies: 2Last Post: 07-01-2007, 04:58 AM


LinkBack URL
About LinkBacks
Reply With Quote
Bookmarks