JavaFAQ Home » Java Applets
If I run my applet with the SUN VM I get exception: "Either "code" or "object"
should be specified, but not both." It does not happen with the Microsoft VM.
I found good recommendations on Sun’s website about how to install latest
browsers and avoid possible problems with running applets in different browsers:
"This is a compatibility issue. To avoid the exception with the Sun VM, do not
use an attribute named object with the PARAM element in an applet.
For Netscape 7, or Mozilla 1.1 or later, running on Microsoft Windows, the
browser will always use Sun's latest JRE—even if you have deselected the
"Netscape 6 or later" or "Mozilla 1.1 or later" check box in the Browser tab of
the Java Plug-in Control Panel. This is due to the auto-scan features of these
browsers. For instance, if Netscape 7 is installed on a Windows machine that has
Sun's 1.4.2 JRE installed as the latest version and you deselect "Netscape 6 or
later" in the Control Panel, Netscape 7 will still run Sun's 1.4.2 JRE (Java
Using Java Plug-in 1.4.2 in conjunction
with Netscape TM 6.x browsers can cause erratic behavior, including closure of
This problem is due to a bug in the browser, and you can avoid this problem by
using Netscape 7.0 browsers.
The Netscape 7 installer provides three
choices for installation: Recommended, Full, and Custom. The Java Plug-in may
not work properly in Recommended or Full installations of Netscape 7 browsers.
Such Netscape 7 browsers may close when attempting to launch an applet. To avoid
this problem, install Netscape 7 using the Custom option, and choose not to
install the Quality Feedback Agent.
When installing Java Plug-in, it is
necessary to shut down and then restart your web browser. On Microsoft Windows
platforms, Netscape 7 has a Quick Launch feature that keeps it running in the
background so that it can be launched with minimal start-up time from a Quick
Launch icon in the system tray. To completely shut down Netscape 7, you must
exit Netscape 7 from its Quick Launch icon in the system tray. "
This tip is based on:
Printer Friendly Page
Send to a Friend
Search here again if you need more info!