How can I upload a (image) file through an applet ?

John Zukowski

Untrusted applets do not have access to the local file system. In addition, there needs to be something listening on the server, waiting for the file. You are better off using a FORM and a servlet. See the Servlet FAQ for how to do this with servlets.

See also How do I upload a file from an applet to a servlet, i.e. emulate the browser's 'multipart/form' ability to upload files?.