Trying to incorporate BrowserPrint into an existing jsp and I'm seeing this (from F12 Developer tools) when I hit my page:
SCRIPT5: Access is denied. File: BrowserPrint-1.0.4.min.js, Line: 1, Column: 95
Using IE11 and the js files are installed on Tomcat server.
Snippet (browserprint code taken from an example found here):
// set vars for printing from resultset var controlnumber = ; var dname = ""; var daddr = ""; var daddr2 = ""; var dcity = ""; var dstate = ""; var dzip = ""; var dphone = ""; var reference = ""; var reference2 = ""; var reference3 = ""; var pname = ""; var pphone = ""; var pieces = ; var dinstruc = "";
// print string (partial for testing) var format_start = "^XA"; var txtToPrint = "^FO50,50^BY3^BCN,100,T,N.N^FD" + barcode + "^FS"; txtToPrint = txtToPrint + "^FO600,50^A0N,50^FD" + p + " of " + pieces + "^FS"; txtToPrint = txtToPrint + "^FO50,200^A0N,50^FDTo: " + dname + "^FS"; txtToPrint = txtToPrint + "^FO50,300^A0N,32^FD" + daddr + "^FS"; var format_end = "^FS^XZ"; alert("print string built.."); // This alert pops.. BrowserPrint.getDefaultDevice('printer', function(printer) { if((typeof printer != "undefined") && (printer.connection == undefined)) { alert("No Printer Found"); // give option to choose printer } else { alert(printer.name); // This alert does not pop - why??? printer.send(format_start + txtToPrint + format_end); } },
function(error_response) { // This alert doesn't pop either alert( "An error occured while attempting to connect to your Zebra Printer. " + "You may not have Zebra Browser Print installed, or it may not be running. " + "Install Zebra Browser Print, or start the Zebra Browser Print Service, and try again."); }
);
BrowserPrint - access is denied... |
1 Replies
OK. what does it take to get an answer to this? It's been at least three weeks (this is a repost) @robinwest