Samer Albahra
unread,Aug 9, 2016, 5:27:51 PM8/9/16Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to PDFTron WebViewer
Hello,
We are developing an application which uses an embedded PDFTron WebViewer. The problem we have is for a few documents when saving a file for offline, it reports success but didn't write anything to the IndexedDB. This is happening in both Chrome and Firefox browsers. I can say it's only three of many documents tested but nonetheless it is occurring. This is the code I am using to save the file for offline (when the viewer isn't open).
var partRetriever = new CoreControls.PartRetrievers.StreamingPartRetriever( location, CoreControls.PartRetrievers.CacheHinting.CACHE ),
doc = new CoreControls.Document( ItemID );
doc.loadAsync( partRetriever, function( err ) {
if ( err ) {
unloadCoreControlDocument( doc );
return;
}
doc.initOfflineDB( function() {
doc.storeOffline( function() {
unloadCoreControlDocument( doc );
}, tick );
} );
} );
The ItemID is an internal pointer to our db ID and the location is the complete URL to the XOD document. The return shown in the browser is a 200 but in the instances where it fails, the browser says: Failed to load response data.
Do you have any idea what may be causing this? If you need additional information please let me know.
Thank you,
Samer