I have a .tex file and I need to generate a DVI file from this. I am using MiKTeX 2.9 under windows. I tried TeXworks, TeXstudio, and Emacs but none of them produce the DVI file. I also run the command latex document.tex but also failed.
I got the error
! pdfTeX error (\pdfobj): not allowed in DVI mode (\pdfoutput <= 0).
\pgf@sys@setuppdfresources@plain ->\pdfobj
reserveobjnum \edef \pgf@sys@pdf@...
l.418 \pgfutil@setuppdfresources
% possibly call the above
No pages of output.
Transcript written on document.log.