title: Why do I get a FileNotFoundException when ClassLoader.getSystemRessource(filename) gives a result?
body: <p>My current application needs to get data from a file to initialize its attributes.
  It needs to be stored in a file to enable modification to the user.</p>
  
  <pre><code>String strFile = ClassLoader.getSystemResource("myFile.csv").getPath();
  if(strFile==null)
          throw new Exception("File not find");
  BufferedReader br = new BufferedReader(new FileReader(strFile));
  //Begin reading file process..
  </code></pre>
  
  <p>My problem is that <code>strFile</code> is not null but I have a <em>java.io.FileNotFoundException</em> when <code>br</code> is initialized, see the following stack:</p>
  
  <pre><code>java.io.FileNotFoundException: C:\Users\TH951S\My%20Documents\Eclipse\Workspace
                                   \My%20App\bin\myFile.csv 
                                   (The system cannot find the path specified)
  at java.io.FileInputStream.open(Native Method)
  at java.io.FileInputStream.&lt;init&gt;(Unknown Source)
  at java.io.FileInputStream.&lt;init&gt;(Unknown Source)
  at java.io.FileReader.&lt;init&gt;(Unknown Source)
  </code></pre>
  
  <p>I checked that the file is in the designated path and everything seems correct.</p>
  
  <p>Does anyone knows why this is happening? Or is there another way to get a file when the path is unknown?</p>
  
  <p>Thanks for reading and more for answering,</p>