I need to access a file that isn't relative to the directory that the .jar file is in.

I got lucky with another part of the program doing this, but I really don't know how.


You can specify a full path from the root (eg c:) to the file, check out the API doc for File. You can also get useful directories like the user's home dir or a temp directory from System.getProperty, eg System.getProperty("user.home") and use that to locate a file.