SecurityException: Unable to create temporary file with applet
My applet tries to write a temp file
try{
File temp = java.io.File.createTempFile("student",".log");
strFilename = temp.getAbsolutePath();
}
}catch (IOException e1){
e1.printStackTrace();
}
But when I run, it throws an exception:
java.lang.SecurityException: Unable to create temporary file
I tried to sign the applet, as to http://www.developer.com/java/data/article.php/3303561 but it's still the same.
There's another way: using java.policy,
grant{
permission java.security.AllPermission;
};
but it seems to be not very gentle. Could you show me the solution please? Thanks in advance.
Cheers,

