> I am writing an applet which contains a TextArea. I want this applet to read text from a text file and display it in the TextArea. I created a File object using the following code : > File f = new File("Text.txt"); > and then went about reading and displaying text. This approach worked fine when I ran the program in appletviewer. When I tried to run the applet in Internet Explorer the text file could not be loaded. Then I changed the above code like this : > File f = new File("C:/Java/Text.txt"); giving the full path name. > This worked fine. But whenever I change directories I have to change the code and recompile. My question is, is there a way to specify the file so that I do not have to write the absolute path? I want to include this applet in my home page where giving the full path name would not be very convenient. Please help.