File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Applets and the fly likes Applet jdbc Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login

Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Java » Applets
Bookmark "Applet jdbc" Watch "Applet jdbc" New topic

Applet jdbc

Nitin Sharma

Joined: Jun 18, 2008
Posts: 8

I am trying to make a jdbc connection from an applet. This works fine if it s run using an applet viewer. But when i try to embed the applet in a jsp ,it throws an exception saying "com.mysql.jdbc.driver" cannot be found. I have added the driver in the lib of the web application that i am building. Can anyone guide me on this?


Ulf Dittmer

Joined: Mar 22, 2005
Posts: 41125
Applets don't use the WEB-INF/lib and WEB-INF/classes directories. You need to put the jar file into a publicly accessible directory (e.g., the one where you keep the other applet class/jar files), and add an archive attribute to the applet tag which specifies the name of the jar file.

Ping & DNS - my free Android networking tools app
It is sorta covered in the JavaRanch Style Guide.
subject: Applet jdbc
Similar Threads
applets with jdbc
Applet connection to DB on webserver
Applets with jdbc
connecting java applet with mysql using JDBC
Proj: Chatting Application