Hey all:
I'm kinda new to java programming, and I'm trying to read in a file from the same folder as the other files.
I've tried just using:
FileReader filereader = new FileReader("index.txt");
and also using:
filename = new String(parent.getCodeBase().toString() + "index.txt");
FileReader filereader = new FileReader(filename);
Both ways give me the AccessControlException ................
How do you guys usually read in file (other than passing it the file name... I'm not reading in from the main(), rather I'm reading the file from a panel of my applet).... or can you only read in a file from the main()??
Thanks a lot!!!!
I'm kinda new to java programming, and I'm trying to read in a file from the same folder as the other files.
I've tried just using:
FileReader filereader = new FileReader("index.txt");
and also using:
filename = new String(parent.getCodeBase().toString() + "index.txt");
FileReader filereader = new FileReader(filename);
Both ways give me the AccessControlException ................
How do you guys usually read in file (other than passing it the file name... I'm not reading in from the main(), rather I'm reading the file from a panel of my applet).... or can you only read in a file from the main()??
Thanks a lot!!!!
