Printing existing pdf from O$ 8.3 Mac

Ben Weinberg ben at pca.com
Mon Aug 23 16:25:20 UTC 2021


Bruno:

This method clips the page content.  It does work faster than other methods, though.

Ben

> On Aug 23, 2021, at 12:04 AM, Bruno Del Sol <bruno.delsol at bydesign.fr> wrote:
> 
>   Hi Ben,
> 
>   I confirm that like Paul I print pdf from Omnis through the finder,
>   here's the code :
> 
>   Begin text block
> 
>   Text:Tell application "Finder"(Carriage return)
> 
>   Text:Print "[path]"(Carriage return)
> 
>   Text:End tell
> 
>   End text block
> 
>   Get text block script
> 
>   Do $root.$runapplescript(script,message) Returns error
> 
>   Regards
>   Bruno
> 
> By Design
> [1]http://www.bydesign.fr
> Bruno Del Sol
> [2]bruno.delsol at bydesign.fr
> 46, rue de La Tour d'Auvergne
> 75009 Paris (France)
> 
>   Le 23/08/2021 à 01:50, Paul Mulroney a écrit :
> 
> Hi Ben,
> 
> What happens if you use "Tell application "Finder" print <file>"?
> 
> Does that work any better?
> 
> Regards,
> Paul.
> 
> 
> 
> On 22 Aug 2021, at 5:18 am, Ben Weinberg [3]<ben at pca.com> wrote:
> 
> Hi Listers:
> 
> I’m printing existing pdfs using the method:
> 
> Begin text block
> Text: tell application "Preview" (Carriage return)
> Text: activate (Carriage return)
> Text: print (POSIX file "[lFilePath]") (Carriage return)
> Text: close (POSIX file "[lFilePath]") (Carriage return)
> Text: quit (Carriage return)
> Text: end tell (Carriage return)
> End text block
> Get text block lScriptText
> Do $runapplescript(lScriptText)
> 
> The file does print but is clipped because of margins being too big.  The pdf’s
> margins are not respected.
> 
> Manual method:
> When I double-click on the pdf, it opens in Preview and prints with much smaller
> margins so it is not clipped.  The pdf’s margin settings are respected.
> 
> Is there a better way?
> 
> I have tried the AppleScript above but using PDFpen, which will print the pdf co
> rrectly, but then hang the Omnis method until I manually quit PDFpen.
> 
> Ben Weinberg
> _____________________________________________________________
> Manage your list subscriptions at [4]http://lists.omnis-dev.com
> Start a new message -> [5]mailto:omnisdev-en at lists.omnis-dev.com
> 
> 
> Q: Why do seagulls live near the sea?
> A: Because if they lived near the bay they'd be bagels.
> 
> References
> 
>   1. http://www.bydesign.fr/
>   2. mailto:bruno.delsol at bydesign.fr
>   3. mailto:ben at pca.com
>   4. http://lists.omnis-dev.com/
>   5. mailto:omnisdev-en at lists.omnis-dev.com
> _____________________________________________________________
> Manage your list subscriptions at http://lists.omnis-dev.com
> Start a new message -> mailto:omnisdev-en at lists.omnis-dev.com 




More information about the omnisdev-en mailing list