Results 1 to 7 of 7

Thread: Can't Run Swing Applet in IE

  1. #1

    Thread Starter
    Addicted Member
    Join Date
    Nov 2000
    Location
    hongkong
    Posts
    251
    I face a strange problem in running my Calculator applet. Its GUI is written

    in Swing, JDK 2 1.3 (i.e. class BinaryCalculator extends JApplet ...). It can
    run
    using appletviewer and my home Netscape 6. But can't run in IE and school
    Netscape
    (I think is 4.x). I have tried updating my IE to 5.5 but still can't run. The
    error message in the IE status bar is:

    load: Class BinaryCalculator not found

    I have also tested the Hello World Swing Applet. The same fate.

    My HTML code is just simple as follows:

    <HTML>
    <HEAD>
    <TITLE>Binary Calculator</TITLE>
    </HEAD>
    <BODY>
    <aPPLET CODE="BinaryCalculator.class" WIDTH=299
    HEIGHT=329></APPLET>
    </BODY>
    </HTML>

    Or

    <HTML>
    <HEAD>
    <TITLE>Binary Calculator</TITLE>
    </HEAD>
    <BODY>
    <aPPLET CODE="BinaryCalculator" WIDTH=299
    HEIGHT=329></APPLET>
    </BODY>
    </HTML>

    and the HTML file and the class file are put in the same folder.

    Do you know what has happened and how can I solve the problem? Is it I need to
    embed the applet as an object using the <OBJECT> tag in the HTML for
    running Swing
    applet properly in Microsoft world. I would be most grateful if you have time to

    reply. Thanks a lot.

  2. #2
    Junior Member
    Join Date
    Dec 2000
    Location
    Reykjavík, Iceland
    Posts
    29

    Smile

    I am not sure but try using Html converter found at
    http://java.sun.com/products/plugin/1.3/converter.html

    I hope this help

  3. #3
    Guest

    Thumbs up The browser needs to know where to find your class


  4. #4
    Hyperactive Member
    Join Date
    May 2000
    Posts
    367
    this might something you already know or not, but swing is not supported by the most popular browsers i.e. Internet Explorer and Netscape. You have do run the html converter on your html file and also force the user to download the java run time environment, its all documented at sun.

    Sorry if you already knew that...

  5. #5
    Guest

    Question Not Only Swing Problems?

    Hey billrogers,
    Could you post a link on that issue? I was recently having problems with IE with a non-swing applet at the end of thread http://forums.vb-world.net/showthrea...threadid=60522 . I posted the versions I used there and I was surprised that only Netscape's worked. I don't recall having this problem before (although it's possible I favored Netscape at the time I dabbled with applets and lately I've been favoring IE and have not been using applets much). Thanks.

  6. #6
    Hyperactive Member
    Join Date
    May 2000
    Posts
    367

  7. #7
    Guest
    Thanks.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  



Click Here to Expand Forum to Full Width