used xod

45 views
Skip to first unread message

Tehila Horvitz

unread,
Oct 5, 2016, 4:49:13 PM10/5/16
to PDFTron WebViewer

Hello

When I convert "pdf" to "xod"  the function rotate and delete doesn't  work

(if I use extension "pdf" it's working)

The code:

Rotate:

readerControl.docViewer.getDocument().rotatePages([readerControl.docViewer.getCurrentPage()], CoreControls.PageRotation.e_270);

Delete

readerControl.docViewer.getDocument().removePages([readerControl.docViewer.getCurrentPage()]);

Thank

Kristian Hein

unread,
Oct 6, 2016, 10:15:03 PM10/6/16
to PDFTron WebViewer
Hello,

XOD files are read only. It is not possible modify them client side.

Instead, it is recommended to keep the original PDF file on the server, and use PDFNet to apply the "split/remove/rotate/etc" commands on the original PDF, and then generate a new XOD from the original (but now modified) PDF. Unless you call PDFDoc.Save and write to the original file location, then any changes you make to the PDF are "temporary".

-Kristian
Reply all
Reply to author
Forward
0 new messages