Tuesday, February 16, 2010

How to Convert a LaTeX file to an Office Format

The following steps are for a GNU/Linux operating system. This will help convert a .tex file to popular office formats like .doc , .odt and HTML format.

Run the following commands:
  1. $ bibtex example.bib
  2. $ latex example.bib
  3. $ tex4ht example.tex
  4. $ mk4ht oolatex example.tex
The odt file will be prepared. This file can be converted into various other formats with OpenOffice.org.

If you are using LyX, there are various conversion options in File -> Export menu. One of them is OpenDocument which will export the file into .odt format.

Note: For the above procedures to work, the package tex4ht should be installed in your system. Some formatting might be lost while converting.

No comments:

Post a Comment