• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
how can I get 'Printer is accepting jobs' property, please?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

how can I get 'Printer is accepting jobs' property, please?


  • Subject: how can I get 'Printer is accepting jobs' property, please?
  • From: Brian Christmas <email@hidden>
  • Date: Thu, 23 Oct 2014 21:56:07 +1100

G’day

I’ve worked out through googling how to set my default printer on Yosemite, but I’d like to be able to check if the printer is actually accepting jobs. The information is listed in the shell scripts returned data, but I can’t find a way to retrieve the setting as a property. Is such a thing possible, or should I parse the data to check for true? Parsing seems such an awkward method.

Regards 

Santa



use AppleScript version "2.3.1"
use scripting additions
use framework "Foundation"
use framework "AppKit"

on run
setPrinter()
end run

on setPrinter()
set defaultPrinterProperties to do shell script ("lpoptions -d Quark_Printer")


set defaultPrinter to do shell script ("lpstat -p Quark_Printer")
defaultPrinterProperties & return & return & defaultPrinter
end setPrinter


Result of Main Script:
--> "copies=1 device-uri=dnssd://HP LaserJet 200 color M251nw (4C7452)._ipp._tcp.local. finishings=3 job-cancel-after=10800 job-hold-until=no-hold job-priority=50 job-sheets=none,none marker-change-time=1412906605 marker-colors=#00FFFF,#FF00FF,#FFFF00,#000000 marker-high-levels=100,100,100,100 marker-levels=100,96,100,87 marker-low-levels=6,6,6,7 marker-names='Cyan\\ Cartridge\\ HP\\ CF211A,Magenta\\ Cartridge\\ HP\\ CF213A,Yellow\\ Cartridge\\ HP\\ CF212A,Black\\ Cartridge\\ HP\\ CF210X' marker-types=toner,toner,toner,toner number-up=1 printer-commands=AutoConfigure,Clean,PrintSelfTestPage printer-info='Quark Printer' printer-is-accepting-jobs=true printer-is-shared=false printer-location printer-make-and-model='HP LaserJet 200 color M251nw-AirPrint' printer-state=3 printer-state-change-time=1412906673 printer-state-reasons=cups-ipp-conformance-failure-report,cups-ipp-missing-send-document printer-type=10522828 printer-uri-supported=ipp://localhost/printers/Quark_Printer

printer Quark_Printer is idle.  enabled since Fri Oct 10 13:04:33 2014"
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
applescriptobjc-dev mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: how can I get 'Printer is accepting jobs' property, please?
      • From: Ron Reuter <email@hidden>
  • Prev by Date: Re: Threading changes in yosemite
  • Next by Date: Re: how can I get 'Printer is accepting jobs' property, please?
  • Previous by thread: Re: Threading changes in yosemite
  • Next by thread: Re: how can I get 'Printer is accepting jobs' property, please?
  • Index(es):
    • Date
    • Thread