Java applet won't run under JRE7, no error displayed in console

放肆的年华 提交于 2020-01-01 14:59:14

问题


Under Windows 7, 64-bit, since upgrading to JRE-7 32-bit, under IE9 32-bit or Chrome, I can't run applets such as this one. Inside the Applet rectangle, I see the message "Error. Click for details"

Clicking on the applet box (blank) leads to a dialogue box:

Application Error 
DrawingLines.class
There was an error while executing the application. Click "Details" for more information.

Clicking "Details" button opens the Java console, but there are no errors, just

Java Plug-in 10.3.0.5
Using JRE version 1.7.0_03-b05 Java HotSpot(TM) Client VM
User home directory = C:\Users\Blah
----------------------------------------------------
c:   clear console window
f:   finalize objects on finalization queue
g:   garbage collect
h:   display this help message
l:   dump classloader list
m:   print memory usage
o:   trigger logging
q:   hide console
r:   reload policy configuration
s:   dump system and deployment properties
t:   dump thread list
v:   dump thread stack
x:   clear classloader cache
0-5: set trace level to 
----------------------------------------------------

The developer's tools console is blank in both browsers.

If I reload the page, I eventually get a kind of deadlock, where the browser stops responding.

Any idea why no error is showing in the console?

(edit) Because my JREs are 32-bit, the 64-bit version of IE9 doesn't run applets. This makes sense, and the browser reports the message "Your browser is ignoring the APPLET tag" or equivalent. I am using 32-bit JREs because I develop some software based on JMF (which is only compatible with the 32-bit JRE).


回答1:


Test the Java Version of your browser plugin first: http://www.java.com/en/download/testjava.jsp

I have both Java 6 and 7 installed on Windows 64 bit. My browser plugin is still the 6 version. I had not updated the plugin for the 7 version yet.




回答2:


Here's what I did to solve the problem:

Java Control Panel -> Java tab -> View... (and manage Java Runtime versions and settings for Java applications and applets...) -> Find

Point the search to the Java folder in the Program Files (for a more efficient search). In my case, the control panel found additionally the JDKs (which I also had installed). It already knew about the two JREs I mentioned in the question above.

I accepted the new findings and applets now work in Chrome and IE9.

My theory is that something linking browsers to JREs was not right (the browser was launching the JRE, hence I got a console and an error message in the applet rectangle, but it wasn't correct somehow). Scanning for the JREs again fixes the glitch somehow.




回答3:


Windows 7 32 bit

Go to start/all programs/java/configure java Temporary Internet Files/Settings Set from none to medium



来源:https://stackoverflow.com/questions/10290867/java-applet-wont-run-under-jre7-no-error-displayed-in-console

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!