aspose file tools*
The moose likes Applets and the fly likes how do we load ................ Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Applets
Bookmark "how do we load ................" Watch "how do we load ................" New topic
Author

how do we load ................

Raghav Mathur
Ranch Hand

Joined: Jan 12, 2001
Posts: 641
can anybody tell me , how to create a jar file , so that by double cliking the jar file icon , the applet is loaded .

Raghav.
rekha joshi
Greenhorn

Joined: Aug 20, 2001
Posts: 6
u can make a jar file by using the following command
jar -cvm file.jar file.class(all the classes)
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16061
    
  21

It depends on the OS. For Windows you could set up the registry so that the "Open" command for a file with the ".jar" extension is "java -jar %1".
However, APPLETS don't work that way! They get loaded when the web page that they're embedded in gets loaded (unless you plan to use the appletViewer). This is automatic, with no clicking involved.
I don't really recommend making jars execute when double-clicked, though. Not all jars are executable - for example the java library jars.


Customer surveys are for companies who didn't pay proper attention to begin with.
Raghav Mathur
Ranch Hand

Joined: Jan 12, 2001
Posts: 641
hi :
<u>Tim Holloway :</u> i know how the applet gets loaded but my question is different .
I downloaded an exam stimulator ....... the file i downloaded was a jar file which on clicking opens
an applet ( the exam stimulator ). ...... so i thought maybe this is an option to open a dowloaded
applet ( which opens by clicking the jar file ).

<u>rekha joshi: </u> the name of my file is "myodbc"...... so am i suppose to write the following
code : <b> jar -cvm myodbc.jar myodbc.class </b>. Tell me if this is correct .
when i type this commend , i get an error ( file not found , myodbc.jar ).
i hope i,am able explain what i want .
thanx
raghav
rax_india@yahoo.com
rekha joshi
Greenhorn

Joined: Aug 20, 2001
Posts: 6
Try using this code
jar -cvf myodbc.jar myodbc.class.
reply me back.
Tim Holloway
Saloon Keeper

Joined: Jun 25, 2001
Posts: 16061
    
  21

That wasn't an APPLET, it was an APPLICATION!
Raghav Mathur
Ranch Hand

Joined: Jan 12, 2001
Posts: 641
All it does it creates a jar file but nothing happens on clicking the jar file icon.
i hope i,am putting up my question correctly .
Originally posted by rekha joshi:
Try using this code
jar -cvf myodbc.jar myodbc.class.
reply me back.

Raghav Mathur
Ranch Hand

Joined: Jan 12, 2001
Posts: 641
still waiting !!!
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: how do we load ................