#1
|
|||
|
|||
Creating macro to convert/print to pdf
Hi all,
I could do with some help please.. I understand you can print/save as PDF within Word 2007 but the file location seems to revert to my documents etc. Is it possible (and some pointers would be appreciated) to create a macro which uses the save/print pdf funtion and save it in the same location as where the original document was opened from? Thanks in advance |
#2
|
||||
|
||||
That's not the behaviour I see - the default save location for creating a PDF via File|Save As (using Word's PDF/XPS option) is the folder from which the document was opened.
__________________
Cheers, Paul Edstein [Fmr MS MVP - Word] |
#3
|
|||
|
|||
Ive opened a range of documents and some save as pdf in the location the doc is and others defualt to document libraries. Im guessing it is possible to create a macro to do as I require?
Thanks |
#4
|
|||
|
|||
Created the macro to print to pdf:
Sub Word2PDF() ' ' Word2PDF Macro ' ' ActiveDocument.ExportAsFixedFormat OutputFileName:= _ ActiveDocument.Path & "\" & ActiveDocument.Name & ".pdf", ExportFormat:= _ wdExportFormatPDF, OpenAfterExport:=False, OptimizeFor:= _ wdExportOptimizeForPrint, Range:=wdExportAllDocument, _ item:=wdExportDocumentContent, IncludeDocProps:=True, KeepIRM:=True, _ CreateBookmarks:=wdExportCreateNoBookmarks, DocStructureTags:=True, _ BitmapMissingFonts:=True, UseISO19005_1:=False End Sub |
|
Similar Threads | ||||
Thread | Thread Starter | Forum | Replies | Last Post |
creating macro for biffurcation in sheets according to data. | Nirik | Excel Programming | 8 | 05-07-2011 05:11 AM |
Macro for Print | sivakl2001 | Word VBA | 6 | 03-24-2011 11:25 PM |
Creating a MACRO | Nikb3522 | Word VBA | 0 | 10-21-2010 05:55 PM |
Print Macro in MS Word | steve207 | Word VBA | 0 | 09-10-2010 02:11 AM |
creating macro | steveb | Word VBA | 0 | 08-14-2010 01:29 AM |