title: How to convert .doc or .docx files to .txt
body: <p>I'm wondering how you can convert Word .doc/.docx files to text files through Java. I understand that there's an option where I can do this through Word itself but I would like to be able to do something like this:</p>
  
  <pre><code>java DocConvert somedocfile.doc converted.txt
  </code></pre>
  
  <p>Thanks.</p>