none
Export word doc to PDF using VBA RRS feed

  • Question

  • Hello

    Im able to save a dynamically generated WORD doc to a PDF by using the feature .. ActiveDocument.ExportAsFixedFormat(..)

    One thing my client has requested is having the PDF bookmark pane on the left hand side open up automatically when a user opens the PDF document.

    Is this possible using the above method? - i dont think it is from what i have read on MSDNS definition of it - googling doesnt bring much help either.  Im guessing you have to use the API provided by Adobe Acrobat for this but i dont have access to that for this project.

    If it is possible then what code in VB can i use to achieve this?

    Thanks

    Thursday, June 28, 2012 8:19 AM

Answers

  • You can specify whether headings or bookmarks in the document are converted to PDF bookmarks in the CreateBookmarks argument of ExportAsFixedFormat. Use

    ..., CreateBookmarks:=wdExportCreateHeadingBookmarks

    or

    ..., CreateBookmarks:=wdExportCreateWordBookmarks


    Regards, Hans Vogelaar

    Thursday, June 28, 2012 8:29 AM

All replies

  • You can specify whether headings or bookmarks in the document are converted to PDF bookmarks in the CreateBookmarks argument of ExportAsFixedFormat. Use

    ..., CreateBookmarks:=wdExportCreateHeadingBookmarks

    or

    ..., CreateBookmarks:=wdExportCreateWordBookmarks


    Regards, Hans Vogelaar

    Thursday, June 28, 2012 8:29 AM
  • Hi Hans

    Thanks for your reply.

    I have been able to create the PDF bookmarks - however what my client is now asking for is when you open the PDF file the bookmarks are automatically displayed/opened on the left hand side.  Normally when you open the PDF you have to expand the left hand pane/click on the bookmarks icon to view them.

    Does that make sense?

    Thanks

    Thursday, June 28, 2012 8:46 AM
  • Yes, your initial suspicion was correct - you'd have to create or edit the PDF file in Adobe Acrobat or using the Acrobat API. You can't set the property to expand the bookmarks pane from Word.


    Regards, Hans Vogelaar

    Thursday, June 28, 2012 9:17 AM
  • Ok cool - thanks again for your input.

    Thursday, June 28, 2012 9:26 AM