Become a MacRumors Supporter for $50/year with no ads, ability to filter front page stories, and private forums.

brijazz

macrumors 6502
Original poster
Jul 31, 2008
420
565
I have two printers. One is named Brother DCP-L2540DW (B&W) while the other is Brother HL-L3270CDW (Colour). I am attempting to print to the latter via AppleScript, but the output always goes to the former. Here's the script:

AppleScript:
tell application "Pages"
    
    activate
    
    set thisDocument to make new document with properties {name:"New Doc", document template:template "Blank", body text:"stuff to print"}
    print thisDocument with properties {copies:1, target printer:"Brother HL-L3270CDW (Colour)"}

end tell


Any thoughts on how to remedy this? I'm on Big Sur 11.4.
 
Register on MacRumors! This sidebar will go away, and you'll see fewer ads.