title: how to access resources(Excel file) in jar file
body: <p>Hi i have exported my java project as executable jar file. inside my project I am accessing a Excel file containing some data. Now I am not able to access the Excel file when I am trying to access the file. <br/></p>
  
  <p>My project structure is:<br/>
  Java_Project_Folder<br/>
   <strong>- src_Folder<br/>
   - resources_Folder(Containing excel file)<br/></strong></p>
  
  <p>I am accessing the excel file like </p>
  
  <pre><code>FileInputStream file=new FileInputStream(new File(System.getProperty("user.dir")
  +File.separator+"resources"+File.separator+"Excel.xlsx"));
  </code></pre>
  
  <p>I have tried accessing this file using <code>getResourceAsStream</code> like:</p>
  
  <pre><code>FileInputStream file=(FileInputStream) this.getClass().getResourceAsStream
  ("/resources/Excel.xlsx");
  </code></pre>
  
  <p>But i am getting in is null exception. whats wrong can anyone help?</p>