I can not catch the errors from document loading failure. I tried the suggestion from this thread
https://groups.google.com/forum/#!msg/pdfnet-webviewer/KYsQN4KmloQ/WoeQ2WRv35oJ
I have explicitly tried the SetErrorCallback like this:
partRetriever.SetErrorCallback(function(err) {
console.log('Hello from error callback!');
});
but the error is not caught.
The server responds with a HTTP 500, since the conversion fails and I get these traces in the Chrome console:
GET http://localhost:9082/TPTRWeb_war_exploded/resource/documents/xod/B8921582F9A59AEF 500 (Internal Server Error) CoreControls.js:348
b.start CoreControls.js:348
_.extend.kj CoreControls.js:352
h.Ha.Nh CoreControls.js:427
h.ba.Nh CoreControls.js:727
exports.ReaderControl.loadDocument ReaderControl.js:1814
readerControl.loadDocument VM757:32
window.ControlUtils.byteRangeCheck.streaming ReaderControl.js:2137
$.ajax.success ControlUtils.js:147
k jquery-1.8.2.min.js:2
l.fireWith jquery-1.8.2.min.js:2
y jquery-1.8.2.min.js:2
d jquery-1.8.2.min.js:2
Uncaught Error: Wrong signature in local header: 1329865020 CoreControls.js:350
_.extend.processData CoreControls.js:350
(anonymous function) CoreControls.js:351
e.Events.trigger CoreControls.js:29
b.onreadystatechange CoreControls.js:348
I need to be able to present a decent error message to the user.
Any suggestions?