I have tried (and sadly failed) to print out the content from a text file into a new Microsoft Word document.
Below is the code from my attempt. Also, I can't download any other additional libraries other than the usual ones.

Microsoft Word won't open up the file as it can't read the contents and says it's corrupt.

Also, is it possible to append other text files to the same MS Word document?

Thank you!

October 26th, 2011, 06:19 PM

copeg

Re: Content in text file to MS Word file help!

Word documents are not just text, they are a particular file format containing all sorts of other important information such as formatting. You will need a 3rd party library - such as Apache POI - to get the actual text of the document, append, and rewrite the file.

October 27th, 2011, 06:26 AM

daniel.j2ee

Re: Content in text file to MS Word file help!

I have only one question here :) Why can't you download/use other libraries?