Rank: Newbie Groups: Member
Joined: 5/10/2016 Posts: 1
|
Is there any way of accessing the HTTP status when using ConvertUrl? We need this to detect 500 errors or similar, so that the PDF conversion can fail in stead of creating a PDF of the error message.
|
Rank: Administration Groups: Administration
Joined: 5/27/2007 Posts: 24,225
|
Hi, Yes. You will need to use this method: https://www.essentialobjects.com/doc/eo.pdf.htmltopdfsession.runwebviewcallback.aspxNote the LoadRequestAndWait method in the sample code. You can change it to LoadUrlAndWait. Both methods returns a NavigationTask object. You can then use this property to check the HTTP status code: https://www.essentialobjects.com/doc/eo.webbrowser.navigationtask.httpstatuscode.aspxHope this helps. Please feel free to let us know if you still have any questions. Thanks!
|