library

i've got a question. a have several library jar files in a directory. i put path to this directory in classpath but doesn't work. i must put in classpath each jar file. is any solution for my problem. thanks for help
[225 byte] By [alcatraz123a] at [2007-11-26 19:05:25]
# 1
I don't know if "C:/whatever/*.jar" would work, but it's worth a try.
hunter9000a at 2007-7-9 20:55:33 > top of Java-index,Java Essentials,Java Programming...
# 2
i've tried fisrt, doesn' work, thanks for advice, but i need more
alcatraz123a at 2007-7-9 20:55:33 > top of Java-index,Java Essentials,Java Programming...
# 3

Nope, each jar file has to be listed, as far as I understand it.

If you really need the dynamic loading of various .jar files in a given directory, you can try using the [url=http://java.sun.com/j2se/1.4.2/docs/api/java/net/URLClassLoader.html]URLClassloader[/url] class to load each file individually from a directory listing.

kevjavaa at 2007-7-9 20:55:33 > top of Java-index,Java Essentials,Java Programming...
# 4
I've heard that you can use wildcards in the classpath (e.g. /thingy/*.jar) in Java 6, but you'd have to look that up to confirm it.However I don't see why it's a problem to have your classpath list all the jar files it needs.
DrClapa at 2007-7-9 20:55:33 > top of Java-index,Java Essentials,Java Programming...