Q:

Can't acces files from runnable jar file

The code in question is simple something along the lines of
File f = new File("Testfile.txt");
f.createFile();

the file would later be written into.  This code is in an executable jar file.  When it is executet via "java -jar jarname.jar" it works fine, but when it's being launched via normal doubleclick, it does not work.  Nothing happens.  So far this seems to be the case because the file created somehow does not actualy denote a file in the directory the jar file is in but that is just an assumption.  For short: how can I create and edit a file from a runnable jar that is being run via doubleclick? 
Thanks in advance

A:

So far this seems to be the case because the file created somehow does not actualy denote a file in the directory the jar file is in but that is just an assumption. 

Correct.  It doesn't.  It represents a file in the current working directory.  What that is when you double-click depends entirely on how the double-click is set up.  Possibly the root directory. 

For short: how can I create and edit a file from a runnable jar that is being run via doubleclick? 

Why?  Why create the file before it's written into?  Don't do this.  The time to create the file is when you create your file output stream or writer.  If that fails you get an exception too, which is more helpful than the Boolean returned by File.createFile(), which in any case you are ignoring.