Opening pdf in read only mode

PDF-XChange Viewer SDK for Developer's
(ActiveX and Simple DLL Versions)

Moderators: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange

alessandro.borsari
User
Posts: 1
Joined: Tue Aug 02, 2022 9:51 am

Opening pdf in read only mode

Post by alessandro.borsari »

Hello,

in our multi-user application, once a user modifies a document,
the corresponding pdf file is deleted and re-created to let everyone see the updated file.
However, this mechanism is blocked if the pdf is still In-Use.
To open a pdf we use ActiveX control PDFXCviewAx.CoPDFXCview.
Once the pdf is open, it is kept locked and cannot be deleted/modified.
Is there a way to open the pdf in just read-only mode?
We need to avoid the pdf being locked.

I really appreciate any help you can provide.
Alessandro.
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19924
Joined: Mon Jan 12, 2009 8:07 am

Re: Opening pdf in read only mode

Post by Stefan - PDF-XChange »

Hello alessandro.borsari,

The Viewer SDK is quite old and I do not have it here for testing but there are get_ and put_ methods for setting a ReadOnly flag for all documents. Please check section
2.5.1.2.3 ReadOnly
of the Viewer AX SDK manual (page 286).

Kind regards,
Stefan