Re: Does Quark 3.32 support Program Linking
Re: Does Quark 3.32 support Program Linking
- Subject: Re: Does Quark 3.32 support Program Linking
- From: Alberto Salvagnini <email@hidden>
- Date: Wed, 11 Jul 2001 10:00:02 +0200
Hi Michael,
I had problems writing a ps file automatically with AS and the friends here
told me that this is a known Problem from Quark.
Now I don't know if your problem on "open CurrentFile" depends also from it.
My droplet works only periodically (! grrr!) so I have another script which
prepared everything for printing and then I just have to save the file in the
folder I choose.
My script which works:
tell application "Desktop Printer Manager"
set the default printer to desktop printer "VirtalPrinter"
end tell
set theDisk to (path to startup disk) as text
tell application "QuarkXPress 3.32r5"
activate
tell document 1
if facing pages = false then
set paper width of print setup to ((page width as real) + 20) as string
else
set paper width of print setup to ((page width as real) * 2 + 20) as string
end if
set page gap of print setup to "0" d
set printer type of print setup to "Acrobat Distiller 4.0"
set reduce or enlarge of print setup to "100%"
set orientation of print setup to portrait
set resolution of print setup to 2400
set include blank pages of print setup to false
set font substitution of print setup to true
set print spreads of print setup to true s
set registration marks of print setup to center
set use PDF screen values of print setup to true
set halftone screen of print setup to 100
TypeText "p" with Command
end tell
end tell
===========================
The (periodical) other script:
tell application "Desktop Printer Manager"
set the default printer to desktop printer "VirtalPrinter"
end tell
set theDisk to (path to startup disk) as text
tell application "QuarkXPress 3.32r5"
activate
tell document 1
if facing pages = false then --wenn die Doppelseiten angeklickt ist
set paper width of print setup to ((page width as real) + 20) as string
else
set paper width of print setup to ((page width as real) * 2 + 20) as string
end if
set page gap of print setup to "0"
set printer type of print setup to "Acrobat Distiller 4.0"
set reduce or enlarge of print setup to "100%"
set orientation of print setup to portrait
set resolution of print setup to 2400
set include blank pages of print setup to false
set font substitution of print setup to true
set print spreads of print setup to true
set registration marks of print setup to center -
set use PDF screen values of print setup to true -
set halftone screen of print setup to 100
-- TypeText "p" with Command
end tell
set theDoc to name of document 1
print document 1 PostScript file (theDisk & "Desktop Folder:" & (theDoc as
string) & ".ps")
copy (theDisk & "Desktop Folder:" & (theDoc as string) & ".ps") to PsDokument
tell application "Desktop Printer Manager"
set statCheck to false
repeat while statCheck is false
delay 2
get queue status of the default printer
if result is idle then
set statCheck to true
end if
end repeat
ignoring application responses
quit
end ignoring
end tell
end tell
tell application "Finder"
move alias PsDokument to alias (theDisk & "Hot Folder:In:")
end tell
Michael Turner schrieb:
>
I am attempting to create a PS output dropplet. Here is my first attempt,
>
which dies on "open CurrentFile". I cant figure out why. The error code
>
reported is "32767". Can anyone let me know what is wrong?
>
>
/Michael
>
>
copy {alias "Kira:Desktop Folder:test1", alias "Kira:Desktop Folder:test2"}
>
to docList
>
>
--on open (docList) -- program intended to be dropplet eventually
>
repeat with CurrentFile in docList
>
tell application "QuarkXPress 4.1"
>
open CurrentFile use doc prefs yes
>
>
-- script dies here
>
>
tell document 1
>
set document 1's print setup to -- next line
>
{orientation:portrait, page position:centered, page
>
sequence:all pages, paper size:"11x17", paper width:"48p", print colors as
>
grays:false, print quality:normal, print spreads:false, print
>
thumbnails:false, printer type:"Color General PPD", registration marks:off,
>
resolution:300, separation:false, tiling:off}
>
>
try
>
print PostScript file (CurrentFile as string) & ".ps"
>
on error
>
display dialog "Error Printing"
>
end try
>
>
end tell
>
end tell
>
end repeat
>
--end open
>
_______________________________________________
>
applescript-users mailing list
>
email@hidden
>
http://www.lists.apple.com/mailman/listinfo/applescript-users
[demime 0.98b removed an attachment of type text/x-vcard which had a name of asalvagnini.vcf]