my dog learned polymorphism
The moose likes Applets and the fly likes html and jar file? Big Moose Saloon
  Search | Java FAQ | Recent Topics
Register / Login
JavaRanch » Java Forums » Java » Applets
Reply Bookmark "html and jar file?" Watch "html and jar file?" New topic
Author

html and jar file?

jordan gong
Ranch Hand

Joined: Jun 12, 2001
Posts: 37
Sir/Madam:
My applet file is Cal.class, and it uses several other class files and a data file in the cc.jar file. When I open the html file, the applet pops up, I can see the textfields, radiobuttons, but the functions do not work. Is there anything wrong with my html code?

<HTML>
<HEAD>
<TITLE>Cal</TITLE>
</HEAD>
<BODY>
<H1>Cal</H1>
<APPLET CODE=Cal.class ARCHIVE=cc.jar WIDTH=450 HEIGHT=550>
</APPLET>
</BODY>
</HTML>
Valentin Crettaz
Gold Digger
Sheriff

Joined: Aug 26, 2001
Posts: 7610
Applet is not part of the Programmer Cert.
I'm moving this to Applets.
------------------
Valentin Crettaz
Sun Certified Programmer for Java 2 Platform


SCJP 5, SCJD, SCBCD, SCWCD, SCDJWS, IBM XML
[Blog] [Blogroll] [My Reviews] My Linked In
jordan gong
Ranch Hand

Joined: Jun 12, 2001
Posts: 37
The code is like this
<HEAD>
<TITLE>Cal</TITLE>
</HEAD>
<BODY>
<H1>Cal</H1>
<APPLET CODE=Cal.class ARCHIVE=cc.jar WIDTH=450 HEIGHT=550>
</APPLET>
</BODY>
</HTML>
Manfred Leonhardt
Ranch Hand

Joined: Jan 09, 2001
Posts: 1492
Hi Jordan,
Object functionality is not related to HTML. Once your applet appears the HTML is complete and your applet java classes take over. Therefore, the fault lies in your java applet code. When the applet has loaded into your browser, look at the Java console and see if any errors are happening. If none are then make sure you have at least registered some listeners and that the methods are actually being called (usually placing a System.out.println call at the beginning of the methds works great).
Regards,
Manfred.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: html and jar file?
 
Similar Threads
My java applet program does not appear in appletviwere!!!
HelloWorld not working
applet not loading
how to run applets classes ?
APPLET in browser...how??