Thomas W wrote:
Quiliro Ordóñez <quil...@...> writes:
when clicking the "View PDF (pdflatex)" icon in LyX, or executing the
appropriate command via the menu, a PDF file is generated in the temp
directory, but Acrobat doesn't start.
I'm using LyX 1.6.1, installed with LyXWinInstaller on a Vista SP1 machine
with Acrobat 8. Any help would be much appreciated, always browsing to the
temp folder is somewhat tedious.
Right click on the saved temp file and click on properties and then
define the type of file and with what program to open with.
Investigate a little. I haven't used Windowz for 8 years.
unfortunately it's not that simple... the file type is correctly associated
with Acrobat, and I wouldn't be sure that LyX looks up the default application
for a pdf in the Windows registry anyways...
maybe this is also helpful - I checked my configure.log, which shows:
+checking for "acrobat"... yes
in -dbg mode the only helpful line seems to be
D:\LyXSVN\LyX1.6.x\src\Format.cpp(303): Executing command: pdfview "C:/Users/one
oftwo/AppData/Local/Temp/lyx_tmpdir.Hp1856/lyx_tmpbuf0/newfile1.pdf"
(no error messages to be found...)
so it seems that the pdfview command is the problem... now how to see/change
what pdfview does?
What happens if you try to run pdfview against the PDF file in the temp
directory from a DOS shell? (You'll need to supply a path to pdfview,
which should be in the LyX bin directory.)
The reason pdfview is involved is that Acrobat Reader puts a lock on
files while it's viewing them. If you edit the LyX file and try to
regenerate the PDF while the previous version is still open in Acrobat,
pdflatex discovers it can't write out the PDF file (it would be
overwriting a file with a lock on it) and punts. So pdfview was
introduced as an intermediary that automatically closes the previous
Acrobat Reader window so that the file can be overwritten, then opens
the new file.
You can change the PDF viewer in LyX from pdfview to just Acrobat
Reader: Tools > Preferences... > File Handling > File formats, select
PDF (pdflatex) if that's what you're using, change the Viewer: field to
acrord32.exe, or maybe try 'auto' first, then save. You may need to add
the path to the Reader binary to Tools > Preferences... > Paths > PATH
prefix, or else supply it in the Viewer: field. AFAIK Reader's
installer does not normally add it to the system command path. If that
works, the problem is with pdfview; if not, the problem lies elsewhere.
/Paul