From mboxrd@z Thu Jan 1 00:00:00 1970 X-Spam-Checker-Version: SpamAssassin 3.4.4 (2020-01-24) on polar.synack.me X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00 autolearn=ham autolearn_force=no version=3.4.4 X-Google-Thread: 103376,bd1f474070392152 X-Google-Attributes: gid103376,public X-Google-Language: ENGLISH,ASCII-7-bit Path: g2news1.google.com!news3.google.com!news.glorb.com!newscon02.news.prodigy.com!newscon06.news.prodigy.com!prodigy.net!newspeer.monmouth.com!nntp.abs.net!news.abs.net!not-for-mail Newsgroups: comp.lang.ada Subject: Re: convert Word to PDF via GNATCOM References: <1139822196.875118.291400@o13g2000cwo.googlegroups.com> From: Stephen Leake Message-ID: User-Agent: Gnus/5.1006 (Gnus v5.10.6) Emacs/21.3 (windows-nt) Cancel-Lock: sha1:GszOh9ak/D2cMMVZjCQXC21Bs8o= MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Date: Mon, 13 Feb 2006 22:06:31 -0500 NNTP-Posting-Host: 66.159.65.1 X-Complaints-To: abuse@toad.net X-Trace: news.abs.net 1139886392 66.159.65.1 (Mon, 13 Feb 2006 22:06:32 EST) NNTP-Posting-Date: Mon, 13 Feb 2006 22:06:32 EST Xref: g2news1.google.com comp.lang.ada:2883 Date: 2006-02-13T22:06:31-05:00 List-Id: "Rod Chapman" writes: > We make makefiles and Word macros to do this. hang on...got it... > Install this in a macro file that is loaded into your global Normal.dot > template: > > Sub pdfprint() > ActivePrinter = "Acrobat PDFWriter" > Application.PrintOut FileName:="", Range:=wdPrintAllDocument, > Item:= _ > wdPrintDocumentContent, Copies:=1, Pages:="", > PageType:=wdPrintAllPages, _ > Collate:=True, Background:=False, PrintToFile:=True, > OutputFileName:="wibble" > > ActiveDocument.Saved = True > ActiveDocument.Close > Application.Quit > End Sub That's not as nice as invoking the "convert to PDF" button; you don't get the table of contents as PDF bookmarks. But I can't actually find the name of the macro that button invokes, so maybe I'll just go with your approach. > We then have a makefile rule that uses Word's little-documented "/m" > command-line > switch: _That's_ what I was looking for! Why can't MS document things like that!? Or perhaps I should ask how you found out about it? Way easier than sorting thru thousands of lines of GNATCOM output. -- -- Stephe