• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Ron McLeod
  • Paul Clapham
  • Bear Bibeault
  • Junilu Lacar
Sheriffs:
  • Jeanne Boyarsky
  • Tim Cooke
  • Henry Wong
Saloon Keepers:
  • Tim Moores
  • Stephan van Hulst
  • Tim Holloway
  • salvin francis
  • Frits Walraven
Bartenders:
  • Scott Selikoff
  • Piet Souris
  • Carey Brown

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

 
Ranch Hand
Posts: 641
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
can anybody tell me , how to create a jar file , so that by double cliking the jar file icon , the applet is loaded .
 
Greenhorn
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
u can make a jar file by using the following command
jar -cvm file.jar file.class(all the classes)
 
Saloon Keeper
Posts: 22505
151
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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.
 
Raghav Mathur
Ranch Hand
Posts: 641
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
Posts: 6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Try using this code
jar -cvf myodbc.jar myodbc.class.
reply me back.
 
Tim Holloway
Saloon Keeper
Posts: 22505
151
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
That wasn't an APPLET, it was an APPLICATION!
 
Raghav Mathur
Ranch Hand
Posts: 641
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
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
Posts: 641
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
still waiting !!!
 
Don't touch me. And dont' touch this tiny ad:
Thread Boost feature
https://coderanch.com/t/674455/Thread-Boost-feature
reply
    Bookmark Topic Watch Topic
  • New Topic