title: Copying .docx Files From One Directory to Another
body: <p>So I was wondering if anyone knew how, or could point me in the direction of some samples that did this in Java? I've tried Googling it, but the examples I find are mostly related to text files.</p>
  
  <p>For example, with this code:</p>
  
  <pre><code>// Copies src file to dst file.
  // If the dst file does not exist, it is created
  void copy(File src, File dst) throws IOException {
      InputStream in = new FileInputStream(src);
      OutputStream out = new FileOutputStream(dst);
  
      // Transfer bytes from in to out
      byte[] buf = new byte[1024];
      int len;
      while ((len = in.read(buf)) &gt; 0) {
          out.write(buf, 0, len);
      }
      in.close();
      out.close();
  }
  </code></pre>
  
  <p>It would not work for a .docx file I don't think, right?</p>
  
  <p>So any ideas?</p>
  
  <p>Thanks in advance for any help that's offered.</p>