Windows electronic printing does not work

I am working on a Kiosk App and I use my Macbook for this, but soft will work on Windows, so I did everything on my macbook and everything works fine, but when I was on a windows machine and create a windows release it does not print and shows no errors, therefore idk how to debug it.

I use the Api printer included in Electron, and as I said, it works on osx !, I do this:

var window = BrowserWindow.getFocusedWindow();
window.webContents.print({
    silent:true
});

The fact is that if I use printing with silent:false, and I select some printer, it sends the job, but it never prints (I can only see the print queue for a second, but it disappears immediately). So, I tried to do it printToPDF(), and it works, it saves the PDF file, I see it.

I tried sending the task to a “PDFGenerator printer” and it generates a PDF file, but it says that it is “not pdf or damaged”

I use:

  • electronically prepared: 0.37.2
  • node: 4.4.2

I hope this makes sense to everyone.

UPDATE

I found a problem, in this version of the electron it does not include "pdf.dll", so you need to copy it or lower it to some value 0.36.x here is the source

+4
source share

All Articles