Need to call dll without any source code on the dll
1 posts in topic
Flat View  Flat View

Posted By:   James_Jenner
Posted On:   Monday, April 2, 2001 09:01 PM


Have a situation where I need to call a dll to integrate with an external application. All the information I have read so far requires compiling the dll with a .h generated from a java program. Is there a way to call the dll direct without the .h or will I need to encapculate?

Thanks in advance.


Re: Need to call dll without any source code on the dll

Posted By:   Scott_Sirovy  
Posted On:   Wednesday, April 4, 2001 07:38 AM

There is no way to do it without the header file -- the OS can't perform the dynamic link step between the C code and the JVM unless the interfaces are in synch.

You'll need to create a wrapper .DLL, creating pass-through function calls for each of the native API calls that you are interested in. This works well, but can be tedious if the interface is complex.

We created a FAX server in Java for a client by wrapping an existing FAX server (with an exposed API) in JNI.
About | Sitemap | Contact