• 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
Re: Printer Setup Utility scripting??
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: Printer Setup Utility scripting??


  • Subject: Re: Printer Setup Utility scripting??
  • From: "Reese, Stevan" <email@hidden>
  • Date: Sat, 18 Mar 2006 18:26:12 -0800
  • Thread-topic: Printer Setup Utility scripting??

Title: Re: Printer Setup Utility scripting??
This is one of the areas where Apple script can be the hard way.
Cups is well documented except where to fine the info. You can set the default printer with just on line.
Here’s how http://localhost:631/sam.html#4_3_3

“Setting the Default Printer

Run the lpadmin command with the -d option to set a default printer:

      /usr/sbin/lpadmin -d printer ENTER”

Wrap the command in a do shell script and you’re done.
stevan



On 3/18/06 4:41 PM, "Adam Bell" <email@hidden> wrote:

I use this little script to switch between two printers connected to my machine - It can probably be modified to suit you:

tell application "Printer Setup Utility"
    activate
    set myPrinters to every printer
    set DefaultPrinter to current printer
    if item 1 of myPrinters is DefaultPrinter then
        set current printer to item 2 of myPrinters
    else
        set current printer to item 1 of myPrinters
    end if
    display dialog (name of current printer) as text default button 1 buttons {"OK"} giving up after 3
    quit
end tell


On 3/18/06, Russell McGaha <email@hidden> wrote:
Folks;
        Anyone have any experience scripting Printer Setup Utility?  I've
got to make sure a certain printer is selected before running a
FileMaker script.  The difficulty comes because I've got to switch
between printers [Fax and laserwitter] in two reports that need to
run unattended; ANY help would be appreciated [even if I need to do
shell scripting]!!

Russell
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden




Stevan
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Applescript-users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden

  • Follow-Ups:
    • Re: Printer Setup Utility scripting??
      • From: "Adam Bell" <email@hidden>
References: 
 >Re: Printer Setup Utility scripting?? (From: "Adam Bell" <email@hidden>)

  • Prev by Date: Re: NSContainerSpecifierError?
  • Next by Date: NSContainerSpecifierError in Address Book
  • Previous by thread: Re: Printer Setup Utility scripting??
  • Next by thread: Re: Printer Setup Utility scripting??
  • Index(es):
    • Date
    • Thread