I need to disable the context menu on the ActiveX plugin in an within an IE Browser after the file has been loaded into an HTML OBJECT element. Reason being I need to track printing of PDF documents via JavaScript and the print action is not detected using the script below. I have disabled the nave panes status and toolbar, the only hole is the context menu print.
Any help would be greatly appreciated.
(function() { var beforePrint = function() { alert('Printing.'); }; if (window.matchMedia) { var mediaQueryList = window.matchMedia('print'); mediaQueryList.addListener(function(mql) { if (mql.matches) { beforePrint(); } }); } window.onbeforeprint = beforePrint; }());