title: Cannot Access Folder in java
body: <p>I need my program to be able to read the files inside a folder, however when I try to compile I'm getting the following error: java.io.FileNotFoundException: (Access is denied)</p>
  
  <p>Here is a section of my code: </p>
  
  <pre><code> String filename="FileCount"; //Replace this with file containing names of files to be processed
   File file=new File(filename);
  </code></pre>