Having looked at the
printing documentation and the
AfterPrint event I am having trouble getting the event to be called.
We have a license and are using build 15.2.8.0. I have verified BeforePrint, but am having trouble with AfterPrint (I understand that this is just the event indicated the print job has been passed on (not completion of the physical print job)). I saw this feature was added as part of this forum post
http://www.essentialobjects.com/forum/postsm37482_EOWebBrowser-wait-for-printing.aspx I have considered trying to get ahold that older build, possibly I could get a PM with the link (since previous build links are not shared on the site).
Problematic code for AfterEvent (I have confirmed that the page prints and event has still not been called).
Note I confirmed that BeforeEvent works as expected.
Code: C#
static void webView_AfterPrint(object sender, AfterPrintEventArgs e)
{
Log.Error("AFTER PRINT EVENT");
}
// ---------------------------------------------
// Register the handler.
view2.AfterPrint += new AfterPrintHandler(webView_AfterPrint);
view2.Print(printerSettings);
I have also tried to verify I wasn't disposing of the runner or the view until after the document actually printed. It might be worth mentioning we are trying to run the browser in a headless configuration
http://www.essentialobjects.com/doc/webbrowser/start/webview_no_ui.aspxI can provide logs or more detailed example code if required. Thanks!