Results 1 to 9 of 9
Thread: access denied
- 05-28-2010, 06:05 PM #1
I've a problem with some things in Internet Explorer.
When I make a applet and run it in my IDE or Firefox its work, but when I run it in Internet Explorer, I got a message: access denied (...)
I got that error when I run a RMI script.
or when I load and draw an Image.
Does someone know how I can fix it?
- 05-29-2010, 03:24 AM #2
When you get errors, please copy and paste the full text of the message.
What versions of Java and Firefox are you working with?
- 05-29-2010, 09:37 AM #3
I got the error message in Internet Explorer 8.0.
Because it's a applet it's doeing "ex.getMessage()" thats only one line.
By loading an image I got this error:
access denied(java.io.FilePermission images\backgrounds\background1.png read)
By starting an RMI program I got this error:
access denied(java.net.SocketPermission 127.0.0.1:1099 connect, resolve)
I've Firefox version 3.6.3
I've Java JDK version 1.6.0_20
I've Java JRE version 6
(and Internet Explorer 8.0)
- 05-29-2010, 02:07 PM #4Senior Member
- Join Date
- Feb 2010
- Waterford, Ireland
- Rep Power
applets cant access the file system
you have to sign them i think
- 05-29-2010, 04:00 PM #5
Your code needs permission to look at the local system. One way is sign the applet. Another is to make changes to the local .java.policy file on the user's computer.
- 05-29-2010, 09:55 PM #6
I've already tried to set all classes and images in a jar file, and signed the jar file.
but than I got the error:
Can't read input file
- 05-29-2010, 10:15 PM #7Senior Member
- Join Date
- May 2010
- Rep Power
- 05-29-2010, 10:33 PM #8
That's interesting that the unsigned version worked in FF 3.6.3 and fails in IE8. I would have thought it would fail in all browsers. Do you have a .java.policy file that gives permissions for anything?
- 06-05-2010, 09:46 AM #9
Sorry for my very late reaction.
I've allready solved it.
When useing an applet it only work when open a file with URL, File doesn't work.
Image img = ImageIO.read(getClass().getClassLoader().getResource("FILE")); //that is the URL
- By parimal in forum Advanced JavaReplies: 22Last Post: 04-09-2011, 05:59 AM
- By sarang1 in forum Advanced JavaReplies: 6Last Post: 02-10-2011, 10:55 AM
- By xcallmejudasx in forum New To JavaReplies: 8Last Post: 05-21-2009, 05:13 AM