[Last Call] Learn about multicloud storage options and how to improve your company's cloud strategy. Register Now

x
?
Solved

annoying problem

Posted on 2002-07-01
17
Medium Priority
?
210 Views
Last Modified: 2011-09-20
im new to java, and i just uploaded my applet to my IIS webserver.

i have an html file with the following code:

<applet
  codebase = "."
  code     = "heartscan.HeartScan.class"
  name     = "TestApplet"
  width    = "453"
  height   = "252"
  hspace   = "0"
  vspace   = "0"
  align    = "middle"
>
</applet>

and then i have a subdirectory called "heartscan" with all my class files in it.

when i visit the heartscan.html file on the web, on the machine i developed the applet on, everything shows up correctly.  However, when anyone else goes to that page they get a "class cannot be found" error or just a grey box.

what is going on??

thanks.
0
Comment
Question by:xorcrack
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 7
  • 4
  • 3
  • +3
17 Comments
 
LVL 2

Expert Comment

by:nir2002
ID: 7123903
Hi,

It seem to be as http server configuration problem.
try that the directory heartscan will be define as
server "root" diectory (or will be at that directory)

Best regards
Nir
0
 
LVL 9

Expert Comment

by:Venci75
ID: 7123936
try this:
code     = "heartscan/HeartScan.class"
0
 
LVL 92

Expert Comment

by:objects
ID: 7124137
Which class is not found?
Is the applet visible on the web to have a look at?
0
Technology Partners: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Expert Comment

by:ucero007
ID: 7124670
I think that the codebase 'parameter' in the applet tag should be set to the directory where the classes are in.

You could try:
codebase = "heartscan/"
0
 
LVL 1

Author Comment

by:xorcrack
ID: 7124792
the applet's path is:

http://medlink.airstreamws.com/HeartScan.html

i have already tried changing the codebase parameter.
0
 
LVL 2

Expert Comment

by:xxMariusxx
ID: 7124849
Applet starts fine for me...I just get a SQLException when it tries to connect to its database.  Probably my security settings though...I'm behind the firewall from hell:-)
0
 
LVL 9

Expert Comment

by:Venci75
ID: 7124902
that is what I got in the java console:
java.lang.ClassNotFoundException: javax.swing.JApplet

Are trying to use Swing without having it installed?
0
 
LVL 1

Author Comment

by:xorcrack
ID: 7125154
where do i have to do to install swing?

again, im new to java programming. i assumed whatever basic libraries i imported would be included automatically.

this could be the problem.
0
 
LVL 92

Expert Comment

by:objects
ID: 7125463
Looks like it's possibly a Java2 applet.
In which case users will need the plugin from Sun installed to run it.
Converting your HTML using the htmlconverter to use the OBJECT tag instead of the APPLET tag will also be required for some browsers.
0
 
LVL 1

Author Comment

by:xorcrack
ID: 7125483
what would my <applet> tag code look like in the form of an <object> tag?

also, i built applet in jbuilder 6, is there a way to tell it not to use java 2?
 
0
 
LVL 92

Accepted Solution

by:
objects earned 400 total points
ID: 7125503
SOmething like this:

<OBJECT
classid="clsid:8AD9C840-044E-11D1-B3E9-00805F499D93"
WIDTH = "453" HEIGHT = "252" NAME = "TestApplet" VSPACE = "0" HSPACE = "0"
codebase="http://java.sun.com/products/plugin/autodl/jinstall-1_4-win.cab#Version=1,4,0,0">
<PARAM NAME = CODE VALUE = "heartscan.HeartScan.class" >
<PARAM NAME = CODEBASE VALUE = "." >
<PARAM NAME = NAME VALUE = "TestApplet" >
<PARAM NAME="type" VALUE="application/x-java-applet;version=1.4">
<COMMENT>
<EMBED
type="application/x-java-applet;version=1.4"
CODE = "heartscan.HeartScan.class"
CODEBASE = "."
NAME = "TestApplet"
WIDTH = "453"
HEIGHT = "252"
VSPACE = "0"
HSPACE = "0"
pluginspage="http://java.sun.com/products/plugin/index.html#download">
<NOEMBED>

</NOEMBED>
</EMBED>
</COMMENT>
</OBJECT>
0
 
LVL 92

Expert Comment

by:objects
ID: 7125508
0
 
LVL 92

Expert Comment

by:objects
ID: 7125513
> i built applet in jbuilder 6,
> is there a way to tell it not to use java 2?

Not sure, but I doubt it.
And it's more of a case of you not using Java 2 capabilities in your development. The default VM in most browsers only supports Java 1.

0
 
LVL 9

Expert Comment

by:Venci75
ID: 7126314
... or if you need only swing, you can find a swing installation at:
http://java.sun.com/products/jfc/download.archive.html#install
0
 
LVL 92

Expert Comment

by:objects
ID: 7126322
> ... or if you need only swing,
> you can find a swing installation at:

Would make it a pretty fat applet :)
0
 
LVL 1

Author Comment

by:xorcrack
ID: 7128124
it was the fact that people needed the Java 2 plugin...thanks!
0
 
LVL 92

Expert Comment

by:objects
ID: 7128264
0

Featured Post

Tech or Treat! - Giveaway

Submit an article about your scariest tech experience—and the solution—and you’ll be automatically entered to win one of 4 fantastic tech gadgets.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article is the last of three articles that explain why and how the Experts Exchange QA Team does test automation for our web site. This article covers our test design approach and then goes through a simple test case example, how …
Basic understanding on "OO- Object Orientation" is needed for designing a logical solution to solve a problem. Basic OOAD is a prerequisite for a coder to ensure that they follow the basic design of OO. This would help developers to understand the b…
Viewers learn about the “for” loop and how it works in Java. By comparing it to the while loop learned before, viewers can make the transition easily. You will learn about the formatting of the for loop as we write a program that prints even numbers…
Viewers learn how to read error messages and identify possible mistakes that could cause hours of frustration. Coding is as much about debugging your code as it is about writing it. Define Error Message: Line Numbers: Type of Error: Break Down…
Suggested Courses

650 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question