Skip to main content
jefft-964
January 13, 2026
Answered

FramerMaker doesn't export chapter number in bookmarks in Acrobat

  • January 13, 2026
  • 2 replies
  • 513 views

When I export my manual from FrameMaker to Acrobat the chapter numbers are not in the bookmarks in Acrobat. How do I get the chapter numbers to show in chapter names in the bookmarks? 

Correct answer frameexpert

I'll try that. I was hoping to export from FrameMarker to get the chapters in the bookmarks instead of renaming the bookmarks in Acrobat. 


Here is an Acrobat JavaScript. I will post a video link explaining how it works and how to use it.

if (app.viewerVersion >= 10) {

    // Add a toolbutton for the command.
    app.addToolButton ({cName: "NumberBookmarksCmd",
        cTooltext: "Number Bookmarks",
        cExec: "numberBookmarks();",
        cEnable: "event.rc = (event.target != null);",
        nPos: 0 });

} 
else { // 9 or below.
  
    // Add the Convert Bookmarks to Title Case menu item to the Document menu.
    app.addMenuItem ({cName: "NumberBookmarksCmd",
        cUser:"Number Bookmarks",
        cParent: "Document",
        cExec: "numberBookmarks();",
        cEnable: "event.rc = (event.target != null);" });
}

// Make a global counter variable to count the bookmarks
// that should be numbered.
counter = 0;

function numberBookmarks () {
	
	processBookmarks (this.bookmarkRoot);
}

function processBookmarks (bkm) {

    var numberRegex = /^Body \- (.+)$/,
        otherRegex = /^[^-]+ \- (.+)$/;
    
    if (numberRegex.test (bkm.name) === true) {
        counter += 1;
        bkm.name = bkm.name.replace (numberRegex, "Ch " + counter + " $1");
    }
    else {
        bkm.name = bkm.name.replace (otherRegex, "$1");
    }

    if (bkm.children != null) {
        for (var i = 0; i < bkm.children.length; i++) {
            processBookmarks (bkm.children[i]); 
        } 
    }
}

2 replies

Dave Creamer of IDEAS
Community Expert
Community Expert
January 14, 2026

I'm getting chapter numbers on my bookmarks. Using the latest version but I don't remember anything different for older versions. I'm using auto-numbering on my headings.

image.png

 

David Creamer: Community Expert (ACI and ACE 1995-2023)
frameexpert
Community Expert
Community Expert
January 14, 2026

Mine are too using FrameMaker 17.0.6. I should have asked more questions. I wonder if the original poster is actually using autonumbers in his chapter titles.

www.frameexpert.com
jefft-964
jefft-964Author
January 14, 2026

No, we are not.

Jeff_Coatsworth
Community Expert
Community Expert
January 13, 2026

What version of FM? Structured or Unstructured? How are you creating the PDF? Publish to PDF or Print to Adobe PDF printer instance?

jefft-964
jefft-964Author
January 13, 2026

Version: 14.0.4.511. Not sure on structured or Unstructured. In FrameMarker, File> Save As PDF

 

Jeff_Coatsworth
Community Expert
Community Expert
January 13, 2026

So that's FM2017 - quite a ways behind the times. Was this working before and now it's not or has it never worked?