[nbusers] Loading native C++ code in NetBeans

  • From:
  • To:
  • Subject: [nbusers] Loading native C++ code in NetBeans
  • Date: Wed, 27 Jun 2012 16:09:00 -0400


Hello all,

I'm trying to load some native C++ code for a security class written in Java.  The code compiles cleanly, but the program throws an UnsatisfiedLinkError at runtime.  Below is a portion of the code from the security class (the goal is to load the .dll file) - did I make an error somewhere?  The isAuthorized method should be executing from the native file.

public native int isAuthorized( );

static
{
        String parentDir = (new java.io.File(System.getProperty("user.dir"))).getParent( );        
        String dllName = parentDir + "\\jendo32.dll";
                System.load(dllName);
                System.out.println("loaded: "+ dllName);
}


[nbusers] Loading native C++ code in NetBeans

Jacob . W . Hill 06/27/2012

Project Features

About this Project

www was started in November 2009, is owned by jpirek, and has 21 members.
By use of this website, you agree to the NetBeans Policies and Terms of Use (revision 20131025.e7cbc9d). © 2013, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo
 
 
Close
loading
Please Confirm
Close