As a web developer, the easiest way for me to solve a problem is normally to develop a web app that takes care of the issue. There are certain advantages to this approach: scalability in that multiple users can access the app simultaneously, accessibility in that it can be accessed from anywhere, and hardware independence meaning if the end user’s computer goes down, all I have to do as IT support is replace their computer. At times, however, there are limitations to this “when all you’ve got is a hammer everything looks like a nail” solution. Most often for me these issues are related to functionality which would be extremely simple in a native application being difficult to achieve from a browser. Thankfully, when I encounter these issues I’m also in control of the end user’s browser and computer.
Most recently, I ran into a situation where I needed a web app to print a packing slip for an online order once that order had been confirmed by the picker and packer. The system I’m using gives the packer easy access to only the computer’s number pad as it was much simpler to repurpose hotkeys–”*”, “/”, etc.–from the number pad than try to find space for a mouse on our packing line. Because of this lack of mouse access, however, I needed the system to be able to print without requiring a click on “Print” in Chrome’s print preview dialogue or the system print dialogue. What I discovered thanks to this page on Vend’s website is that Chrome has a little-known kiosk mode with the option for “silent” printing. That is, printing which doesn’t require the user to confirm the printing.
I have Chrome launching on startup for our packers (on a Windows 7 Starter netbook) and all I had to do was right click on the Chrome shortcut in the startup folder, click “Properties” and add the following flags to the end of the “Target:” field:
As the name of flag suggests, this would also be an extremely useful solution in a case where Chrome were running in a Kiosk computer.
A few things to note if you do use this solution to silent printing in Chrome:
- “Print Preview” must be enabled in Chrome. Check “about:flags” and make sure.
- Slightly annoyingly, Chrome will still show the print preview for about a second before going ahead and printing so it’s not quite silent printing, more like muted printing, but it does not require user confirmation, which was my goal.
- This is not a way to auto-print on a users’s computer if you don’t have access to the machine yourself since it requires modifying Chrome’s launch flags. This is a good thing! Imagine visiting an unscrupulous webpage and having it auto-print itself wasting your ink and paper!
- Make sure you have the correct printer selected as the default since that’s the one Chrome will print to.
- Thanks to Matthew McIntyre for pointing out in a comment here that you can omit the
-kioskflag if you want to use silent printing but don’t want Chrome to open full-screen. Different scenario to mine, but useful to note.