• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Help needed -- Applet fails

 
Mike London
Ranch Hand
Posts: 1217
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In my applet, using code to connect to a servlet, on the line where I try to use a Objectstream I get a java.net.unknownProtocol error. It says that output is not allowed with this protocol.
What's REALLY strange is that the code doesn't always fail, just sometimes -- especially when I first install it on a new machine.
Of course I restart Tomcat 4.1.18, and reboot the computer (including a cold boot for good measure), but these actions don't seem to help.
The applet and servlet are on the same machines. I'm using the Java plugin and IE6. WIndows 2000 Pro.
The code that sets up the protocol is below.
URL currentPage = getCodeBase(); // get base URL of the applet
String protocol = currentPage.getProtocol();
String host = currentPage.getHost();
int port = currentPage.getPort();
Any ideas as to what might be wrong would be greatly appreciated.
Thanks in advance!!!
-- Mike
 
Mike London
Ranch Hand
Posts: 1217
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Please disregard this message.
The problem turned out to be that I was missing a JAR file in the Tomcat Libs directory.
Thanks anyway. <s>
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic