title: java.io.FileNotFoundException The system cannot find the path specified
body: <p>I have a timer set to invoke a class that contains pdf generating codes.I have set the file path where it needs to be saved..but it is showing exception as java.io.FileNotFoundException : D:\ (The system cannot find the path specified) .I dont know where is the mistake..</p>
  
  <p>Here is my code..</p>
  
  <pre><code>try {
  
          OutputStream file = new FileOutputStream(new File("D://"));
          Document document = new Document();
           //PDF generating code..     
          document.add(list);            //In the new page we are going to add list
          document.close();
  
          file.close();
  
          System.out.println("Pdf created successfully..");
  
      } catch (Exception e) {
          e.printStackTrace();
      }
  </code></pre>