Skip to main content
Participating Frequently
June 6, 2014
Question

C-Plus set bookmark for PDF to FO_PgfFmt when FO_PgfFmt is defined in master page

  • June 6, 2014
  • 1 reply
  • 387 views

Using the following across all documents in a book

pgfId = F_ApiGetNamedObject(docId, FO_PgfFmt, "100_TOC_Header01");

F_ApiSetInt(docId, pgfId, FP_AcrobatLevel, 1);

pgfId = F_ApiGetNamedObject(docId, FO_PgfFmt, "010_01_00_Heading01");

                        F_ApiSetInt(docId, pgfId, FP_AcrobatLevel, 2);

F_ApiSetInt( bookId, docId, FP_DocAcrobatElements, False);

F_ApiSetInt( bookId, docId, FP_PDFBookmark, True);   

F_ApiSetInt( bookId, docId, FP_PDFBookmarksOpenLevel, FV_PDFBookmarksOpenAllLevels);

F_ApiSetInt( bookId, docId, FP_PDFRegistrationMarks, FV_PDFRegistrationMarksNone);

F_ApiSimpleSave(docId, F_ApiGetString(FV_SessionId, docId, FP_Name), False);

to set bookmarks for PDF when doing a save as PDF on the book.

This works for all FO_PgfFmt's defined in the document except when the FO_PgfFmt is defined in a master page.

Is there some setting that is needed to get bookmarks from master page FO_PgfFmt's?

Or is there some setting that needs to be done on the master page to get the bookmark set?

Any advice or directions would be helpful.

Using FrameMaker 7.1 on Windows 7.

    This topic has been closed for replies.

    1 reply

    Bob_Niland
    Community Expert
    Community Expert
    June 8, 2014

    > ... to set bookmarks for PDF when doing a save as PDF on the book.

    > This works for all FO_PgfFmt's defined in the document except when

    > the FO_PgfFmt is defined in a master page. Is there some setting that

    > is needed to get bookmarks from master page FO_PgfFmt's?

    I'm not familiar with this API, but you appear to be seeking to do something that is impossible.

    Master Pages, per se, never exist in a rendered PDF, so no functional link can point to one.

    Master Pages are used to generate body pages, but a PDF could have multiple instances of the same MP, which would result in multiple targets for links, so no attempt to do so is made during PDF generation (even if your document has only one such MP present).

    Reference Pages are a similar situation. You can actually have a cross-reference to RP content, and it renders as a hypertext link in the PDF, but goes nowhere when you click on it.

    rmg007Author
    Participating Frequently
    June 12, 2014

    There must be a way (via C plus) to set a bookmark on a component that is defined in a master page.

    If so how?

    If not then how would one import (via C plus) the component where used from the master page into the document.

    After doing this the setting of PDF bookmarks should work as it does for other components defined in the document.

    Thanks for any help or advice.

    Arnis Gubins
    Inspiring
    June 12, 2014

    What "component" specifically are you trying to bookmark on a Master Page (a screenshot would help - use the camera icon to upload the image)?

    Why would you need to "import" this into your document flow anyway (if it's in the background it will already appear on every page as Error indicated)? A Master page is just a "cookie cutter" representation of what a page should look like when applied to a continuous flow of content (i.e. the rolled out dough...). If you're using the Master Page to store items for re-use, then that's not the place for it - use a Reference page. FYI, FM ignores all content within a flow text frame on a Master page. That text frame is just the container for the flow content to be used on a Body page (so anything in there from the Master page is thrown away when applied to a Body page).