17

I don't know if this is possible on Adobe Reader DC on Windows, but asking in case someone has managed to do it.

When I am working on a large document in LaTeX (I use TexStudio) I sometimes like to keep a second copy of my PDF on a second screen so that I can easily refer to what I wrote before, while on my main screen I would have TexStudio with its preview window, which is typically automatically in sync with my current editing location.

On Ubuntu (which uses evince as its default PDF viewer) I used to do it quite nicely. It also seems to watch the PDF file for updates, and keeps in sync of any new versions of the PDF file and reloads it (staying on the same page) when I re-run pdflatex from TexStudio.

At the moment I am working on a Windows machine, and I am trying to recreate the same workflow. I would really like to open a second viewer on my second screen so that I can navigate easily to previous chapters without losing my current position in TexStudio's preview window (which will anyway go back to the current editing location when I run pdflatex).

The only problem however is that when I open the PDF in Adobe Reader DC to put it on the second screen and then I try to recompile the PDF I get the error "I can't write to file". I presume that for some stupid reason Adobe Reader DC maintains some write lock on the file, probably keeping it open while the PDF is visible on screen.

Is there a way to disable this stupid file-locking behaviour from Adobe Reader DC?

UPDATE

After some valuable comments, a workaround is possible using a different viewer. One could either use SumatraPDF or evince (the default PDF viewer on Ubuntu, but also available for Windows). They are not so feature rich, and maybe do not look so nice, but in this case do the job.

A similar question was posted here for reference.

  • 1
    I don't think it is a viewer issue but rather a Windows issue as Adobe Reader doesn't lock the files on either Mac or Linux. – ArTourter Jan 19 '16 at 23:59
  • 1
    Try another PDF viewer like Sumatra... – Paul Gaborit Jan 20 '16 at 0:05
  • 1
    Two possibilities: get a different OS (recommended but I see you've tried that already) or get a different viewer (remaining option). – cfr Jan 20 '16 at 0:19
  • 1
    @ArTourter Yes it is a viewer issue. You can open a file and close it without keeping a file lock on Windows just as in Linux. It is just that Adobe is programmed to keep a lock on the file or keep it open for no reason (instead of opening and skipping to the file location it needs on demand). In fact SumatraPDF allows you to do it. – jbx Jan 20 '16 at 0:23
  • 7
    Under Windows, SumatraPDF is the best choice: not only it is lightweight, ultrafast, doesn't lock the files, but it can do direct and inverse search, and there is a 64 bit version. – Bernard Jan 20 '16 at 1:08
11

Been a few months since I asked this question, so I figured would be good to give it closure, for anyone facing the same problem.

The best solution I found is to install SumatraPDF. It is very lightweight and brings back the long lost user experience of opening a PDF almost instantly (I can't recall when Adobe's PDF Viewer last was so fast... maybe in version 4!)

Yes it is slightly uglier looking, with a weird menu button and frameless tabs, but I just care about the PDF I am reading. It also supports viewing two pages at once (book view) and continuous scrolling, just like Adobe PDF viewer. SumatraPDF doesn't have that annoying side-bar Adobe PDF shows with useless tools no one ever uses, that takes seconds to load and there is no evident way how to switch it off by default.

All in all a positive experience, and I am glad I had this problem and discovered SumatraPDF... now my default PDF reader.

  • 2
    Glad you personally found a solution, but it won't work for anyone that needs a feature Adobe has that Sumatra does not - such as reflow and form filling. – Jonathan Baldwin Dec 6 '16 at 16:27
  • @JonathanBaldwin well that was not part of the scope of this question. If you are doing form filling you are then creating a form template with pdflatex. If you are also filling it on the fly (why would you want to do that?) you have a completely different workflow than the one I described. For reflow view, that only applies for smaller screens, again does not fit the scenario described. – jbx Mar 18 '18 at 11:51
0

Having a similar problem, I just found out that ghostview can read .pdf files (and it automatically refreshes). I've always used (from a shell) latex then dvips and viewed the resulting .ps file in ghostview. Now I can just use pdflatex (which is useful as I now need to import .png files which I think couldn't be done with dvips), and view the resulting refreshed .pdf in ghostview.

Ghostview is great as it has a simple unclutterred interface and keyboard shortcuts for efficient navigation (and you can have files open on multiple Nvidia desktops in Windows, whereas Adobe seems to only let you open files in one desktop).

Update (13 Mar 2018): now with a new computer and recent installation of ghostview (gs version 9.22) the refresh (just hitting r) no longer works and I have to reload the file (Alt-F-O ) - fast, but loses the page I was on so not ideal. Now using SumatraPDF as suggested above and it works great (automatically refreshes).

0

Rather than try and add comments to every suggestion to use SumatraPDf to "replace" Acrobat

I will explain here that for a very long time it has always been the case that SumatraPDF positions itself as a Lightweight Viewer with the ability to call Acrobat (amongst others) if needed.

During installation SumatraPDf looks for other PDF application signatures and if it is happy will then automatically adjust its menus to allow you to call Acrobat from the File Pull down. Like this

enter image description here

Note:- that when it finds GhostScript it becomes both an EPS viewer and PS viewer useful now that GSView 6.0 has gone.

In addition to SumatraPDFs native ability to change images such as PNG or AnimGIFs to PDF both EPS & PS can also be saved to PDF.

During compilation SumatraPDF will keep re-freshing or adjusting the view. At any time you want to check what it looks like in Acrobat you can go File open in Acrobat just make sure you close Acrobat or Adobe Reader before another preview or compile.

Note there is a open/close acrobat tool for W32tex but I find it so much easier to use 1 portable SumatraPDF.exe with so many desirable features and that internal call to a portable Acrobat Reader, is the greatest.

Back to supported viewers it is not fool proof and I personally preferer to do this part manually by hand now that Windows 10 interferes even more in "pushing me off" to the Edge of reason.

For manual entry should the following not be adequate its as easy as adding something similar to this to advanced settings file .

ExternalViewers [
    [
        CommandLine = c:\path to the \acrord32.exe "%1"
        Name = Adobe Reader
        Filter = *.pdf
    ]
    [
        CommandLine = fix.cmd "%1"
        Name = FixPDF
        Filter = *.pdf
    ]
]

Signatures looked for (in addition to Ghost Script) are

\AcroRd32.exe \Acrobat.exe \Foxit Reader tracker \PDFXCview.exe windows \xpsrchvw.exe htmlhelp \hh.exe

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.