Java Mailing List Archive

http://www.junlu.com/

Home » Home (12/2007) » Apache Tomcat »

Re: using a dll in a webapp

Christopher Schultz

2006-12-15

Replies:

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Abid,

Abid Hussain wrote:
> I want to establish a connection to a serial port from my webapp by
> using the javax.comm package which uses the win32com.dll (on windows
> systems).
>
> I resolve the path of the dll in my webapp:
> String win32com = new
> File(this.getClass().getClassLoader().getResource("win32com.dll").toURI()).getPath();
>
> Now, I add the path to the java.library.path property:
> System.setProperty("java.library.path",
> System.getProperty("java.library.path") + File.pathSeparator + win32com);

It looks like you are adding the path to the DLL /including/ the
filename. I believe that you want to include the path but /not/ the
filename.

- -chris

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (MingW32)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFFgqyB9CaO5/Lv0PARAoyvAKCmbNynmnBsJWAtLDDS04A1cCRAfgCfRSwA
8JSVeCm3CH3bkmA+yrfk6/4=
=suZt
-----END PGP SIGNATURE-----

---------------------------------------------------------------------
To start a new topic, e-mail: users@(protected)
To unsubscribe, e-mail: users-unsubscribe@(protected)
For additional commands, e-mail: users-help@(protected)

©2008 junlu.com - Jax Systems, LLC, U.S.A.