Skip to main content
Question

Forcing Chrome to use the system print dialogue command not working in script


Forum|alt.badge.img+3

I have been working on a quick printer setup for my users who are not enrolled in the jss (contractors who byod). Basically I converted the driver installer to source in compser, then in the postinstall script added an lpadmin command to add the printer, and added a command to make chrome use the system print dialogue.

The command is:
defaults write com.google.Chrome DisablePrintPreview -boolean true

when entered into terminal it works, but when run in a script it isn't taking

3 replies

Forum|alt.badge.img+16
  • Valued Contributor
  • 1002 replies
  • March 22, 2017

It probably sets it in user space, the script will set it globaly which might not be something Chrome looks at.
You can either have the script defaults command reference the plist for each user directly /Users/$USER/Library/Preferences/com.google.Chrome.plist or use custom configuration profile to enforce the setting.


boberito
Forum|alt.badge.img+22
  • Jamf Heroes
  • 449 replies
  • March 23, 2017

Do it via Configuration Profile and Custom Settings

<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd">
<plist version="1.0">
<dict>
    <key>DisablePrintPreview</key>
    <true/>
</dict>
</plist>

Forum|alt.badge.img+18
  • Esteemed Contributor
  • 831 replies
  • March 23, 2017

Link to older discussions about this:
Discussion 1
Not sure if this helps

Gabe Shackney
Princeton Public Schools


Reply


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings