On Apr 30, 2008, at 8:15 AM, jean-michel T wrote:
I achieved to reproduce my error on a sandbox.
I have then in my code:
libWrapper = LibCommWrapper.INSTANCE
libWrapper.initialize_dll();
new LoginFrame().displayView();
int value = libWrapper.authenticateUser_dll(new
String(password).getBytes());
Does it make a difference if you swap the last two lines (i.e. do your
authenticate first)?
The LoginFrame class is a simple frame that does'nt do anything but
uses the class WindowsUtils (in the jar jna-examples) to create
round borders with the method :
WindowUtils.setWindowMask(this, getArea(getSize()));
If i run this code i get the authentication error with an int having
value of 10 as a result (while the initialization was ok).
If i run this following almost same version which does not call the
frame using JNA
libWrapper = LibCommWrapper.INSTANCE
// libWrapper.initialize_dll();
new LoginFrame().displayView();
int value = libWrapper.authenticateUser_dll(new
String(password).getBytes());
.. then it appears that the authentication succeeds and I got a 0 as
an answer.
You've commented out initialize_dll(). Is that significant? What
does it do?