Using the command window to convert LaTeX to HTML [closed]

I am trying to convert a LaTeX file to HTML. I have tried to do this by typing cmd into the search bar of the START menu. When the black background box comes up, I type in htlatex filename.tex where instead of filename I write the name of the file. It then comes up,

I can't find file filename.
Please type another input file name.


I am using MiKTeX and Windows 7.

-

closed as off topic by Werner, Marco Daniel, qubyte, morbusg, diabonasDec 28 '11 at 18:28

Questions on TeX - LaTeX Stack Exchange are expected to relate to TeX, LaTeX or related typesetting systems within the scope defined by the community. Consider editing the question or leaving comments for improvement if you believe the question can be reworded to fit within the scope. Read more about reopening questions here.If this question can be reworded to fit the rules in the help center, please edit the question.

You need to change to the folder that contains filename.tex using cd the\folder\that\has\the\file. Under Windows (7), if the folders have spaces in them, you can press <TAB> to auto-complete the folder name, or use quotes: cd "\Document and Settings\Users\XYZ\Documents\LaTeX", and then use htlatex filename.tex. Regardless, this is off-topic. –  Werner Dec 28 '11 at 17:43
@Werner: I also think it is off-topic but you can provide an answer -- "First steps inside the command window". –  Marco Daniel Dec 28 '11 at 17:45
This is your fourth question on TeX.SX and we welcome new questions. However, you have not accepted any answer to any of your questions here and you have neither voted on any of the answers you have gotten. Please see the faq for details on accepting and voting. –  N.N. Dec 28 '11 at 18:20

You need to change to the folder containing filename.tex before executing htlatex filename.tex. Under Windows, this can be achieved using

cd path\to\the\folder


You can either use backslashes \ or forward slashes /. If your path contains spaces, you can either use TAB to let Windows auto-complete a partially completed folder name (that is, you type cd Docu and press TAB and Windows will auto-complete this to cd "Documents and Settings"), or use quotes to denote the folder names, for example

cd "Documents and Settings\Users\XYZ\Documents\My Documents"


Once in the correct folder, use

htlatex filename.tex

-