• 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 Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Applet deployment problem

 
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

i am using IIS as web server and i have placed a java applet class file and a html file
in the virtual directory
When i try to access the applet from a client machine which has java installed
in it the applet shows up properly
but when i access the file from a machine which does not have java
(only the jvm in the browser is available) the applet shows
load: class classname not found error
what could be the problem?
i have given the codebase and code attributes in the html file applet tag properly
still i could not access it
Can any one say the steps involved in deploying an applet?
what am i missing?

Advance thanks for your time and help
Siva
 
Bartender
Posts: 9626
16
Mac OS X Linux Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
So you can see the applet when you have the Java Development Kit installed, but you can't see it if you don't. That would lead me to believe that the applet is properly installed and it's the client that is the problem. Specifically the problem is that the version of Java Windows has by default is incompatable with the one you've written your applet in. The Microsoft JVM is ancient, equivalent to JDK 1.1.4. Your client will have to download the Java Runtime (JRE) from here or you can rewrite your applet tag to prompt the install by using OBJECT and EMBED tags.
 
Sivarama subramanian
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Joe
Thanks for your quick reply

I tried the object tag solution you provided and that worked fine

I am just looking for some solution that doesnt require download and installation of new version of jre

What i am currently using for testing purposes is just the traditional hello world applet. It contains nothing else

will there be a clash between 1.4 and 1.1 in even this sort of applet?

I am a newbie in java and please answer my question.

Siva
 
Joe Ess
Bartender
Posts: 9626
16
Mac OS X Linux Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator

Originally posted by Sivarama subramanian:

will there be a clash between 1.4 and 1.1 in even this sort of applet?



Code?
 
Sivarama subramanian
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Only the following code is in the applet used for testing purposes.

import java.applet.*;
import java.awt.*;
import java.io.*;
public class testapp extends Applet
{
public void init()
{
}
public void paint(Graphics g)
{
g.drawString("hello world", 10, 10);
}

}
 
Joe Ess
Bartender
Posts: 9626
16
Mac OS X Linux Windows
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I happened to have the JDK 1.3.1-b24 around for an old Weblogic server and it turns out that if you compile your applet with that JDK, the applet works in IE. JDK 1.3.1 must be more compatable with the old MS VM than 1.5.0. 1.4.2 is still available on Sun's website. You could try it.
Sun is of the opinion that you should install the plug-in because MS's VM is frozen.
 
Greenhorn
Posts: 26
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
If you are compiling from the command line, try putting "-target 1.1" in your command.
 
Sivarama subramanian
Greenhorn
Posts: 4
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi

I compiled with lower version of java and the test applet worked fine and it doesnt throw any error now

My existing situation does not allow me to download any newer version of jre or plugins :-(

But i have to rewrite my original applet to make it extremely thin so that it compiles against the lower version. Currently there are a lot of extension classes used in that applet and everything has to be scaled down to use simple classes.

I'll start working on that from now and i'll come back for any clarifications :-)

I am extremely thankful for your help and quicker responses.

Thanks
Siva
 
reply
    Bookmark Topic Watch Topic
  • New Topic