Win a copy of The Little Book of Impediments (e-book only) this week in the Agile and Other Processes forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

i have problem with Accessing files

 
ayman elgharabawy
Greenhorn
Posts: 19
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i made a swing applet and it works fine on appletviewer but when i use IE 6 i have error
"java.security.AccessControlException: access denied (java.io.FilePermission c1.gif read)
"
where c1.gif is a gif file of a ImageIcon
 
Maulin Vasavada
Ranch Hand
Posts: 1873
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
hi
i really wonder why "Rob" didn't yet jump in if none else did so far into this?? may b Rob is busy...anyways...
do u try to access local gif? meaning something like c:\yourfolder\images\image.gif? (on Windows) OR /usr/home/yourlogin/images/image.gif (On Unix)??
if so then i would suggest that u can try using policy file settings to allow read access to the image file you have.
Following link might be helpful about PolicyTool,
PolicyTool Help
This policy file (java.policy OR .java.policy as you would read in the above mentioned link) will be there in your local machine as the applet is being executed on your machine (though within the browser JVM)...
i don't know if setting policyfile would work with IE but if you are using NN6/7 then you can have this policy file settings then go to the browser's Java Console use "Reload policy settings" option (for which "r" is the command in JavaConsole) and see if the applet works for you??
hope i could be of any help...
regards
maulin
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic