title: Resources access problem from JAR
body: <p>I have the following directory structure of a project:</p>
  
  <pre>
  Folder "project" in Eclipse:
  --folder "src"
  --folder "resources"
  ----trayicon2.png
  --folder "db" 
  ----test.db
  --folder "bin" 
  </pre>
  
  <p>I'm accessing the image with:</p>
  
  <p><code>Image image = Toolkit.getDefaultToolkit().getImage("resources/trayicon2.png");</code></p>
  
  <p>and from Eclipse that is not a problem. 
  Then I generate an "executable jar file", and add the dirs, making a directory structure of:</p>
  
  <pre>
  Folder "project"
  --folder "db"
  ----test.db
  --folder "resources"
  ----trayicon2.png
  --project.jar 
  </pre>
  
  <p>And now the image is no more accessible. Also, the database is no more accessible; while in Eclipse I used to access it with:</p>
  
  <p><code>Connection conn = DriverManager.getConnection("jdbc:sqlite:db/test.db");</code></p>
  
  <p>How can I access the resources (images and db) after generating the jar file "project.jar"?</p>