-- classic print.scpt -- Pass a Postscript file to the printer proxy application -- Written by Toshi Nagata, 2005/03/11 -- Copyright 2005 (c) Toshi Nagata. All rights reserved. -- Original idea from macosxhints -- http://www.macosxhints.com/article.php?story=2005030316173578 on adding folder items to this_folder after receiving added_items set printer_name to the name of the (info for this_folder) set printer_path to (path to home folder as text) & "Library:Printers:" try set print_proxy_app to (printer_path & printer_name & ".app:Contents:MacOS:PrinterProxy" as alias) on error display dialog "Printer '" & printer_name & "' is not available. Print job is suspended." buttons {"OK"} with icon caution default button 1 return end try set the_file_list to "" repeat with i from 1 to number of items in added_items set the_file to (the name of the (info for item i of added_items)) if the_file is not ".DS_Store" then set the_file_list to the_file_list & " '" & the_file & "'" end if end repeat set the_script to "cd '" & the POSIX path of this_folder & "'; ~/Library/Scripts/classic_print_wrapper '" & printer_name & "' " & the_file_list do shell script the_script end adding folder items to