I've run into an odd scenario. I have several chapters (separate FM Documents) in my book. The first chapter in my book has the Chapter Numbering set to 1:
All other chapters are set to "Continue Numbering from Previous Chapter in Book."
After updating the book, when I open each Chapter (FM document), the chapter number shown is correct: the first numbered as Chapter 1, the second as Chapter 2, etc. The chapter numbers in the TOC are also correct.
When I convert the book to PDF (Save as PDF or Publish), however, the numbering is reset, with the first chapter being Chapter 0, with the subesequent Chapters numbered sequencially from there.
When I open the chapters (FM documents) to check, they still show the correct numbering.
Any suggestions as to why this is happening? I can't find any reason for the the numbering to change during the PDF generation process.
○ Read from File
means that this is the book-level Numbering dialog.
There is some chance that the Book numbering & component file numbering don't match.
My usual practice is to set numbering in the component files themselves, then set the .book tree to
⦿ Read from File
When I select the Book, I don't have an option to set the Numbering:
Because we have different page numbering for certain documents in the book as well as the specific Chapter numbering that are document specific, I've always set the numbering at document level. I've not had this behaviour before.
re: When I select the Book, I don't have an option to set the Numbering:
Correct. Instead, right-click on each book name in the book's tree.
The options there are stored in the .book file, and they can differ from what's in the component .fm files.
I'm not sure I follow. In the Book Pod, I only have 1 book listed. When I right-click on it, I don't have access to the Numbering.:
Do you mean right-click on each document within the book?
That is how I am setting the Chapter numbering.
re: Do you mean right-click on each document within the book?
Correct, although it appears that if this is a Structured document, there's yet another place for Numbering to become confounded.
I have no idea why the numbering would change on the PDF export. The only idea I have is that you're not looking at the same version of the PDF? Is that a possibility? So, for example, in the book window, choose File > Save as PDF (which uses the last settings from the publish pod), when it completes the conversion, choose the View Output button, so that you're looking at the PDF that Fm just created. Is it really changing the numbering during the export?
That was my through too, but then I deleted the PDF to make sure and recreated the PDF - still had the change in chapter numbering.
As another test, I changed the first Chapter's numbering to start at 2. When I generated the PDF, the chapters were numbered from 1 onwards.
Copy link to clipboard
Can you please confirm that the paragraph style displaying your chapter number is using the chapnum building block? It's possible that the paragraph style itself is using an independent numbering scheme.
Yes, the Element's paragraph definition it's definitely using the <$chapnum> system variable:
Bingo...you're using chapnum in a structured book.
Set your numbering in the EDD using the elemnum instead
I'm very confused now. This is how the Chapters are numbered in all our Structured Books. None of them present this issue. This is the only Book that is behaving this way when converted to PDF.
In the EDD, the Element definition is:
With the FormatChange List as:
Please share the structure view of your book file.
Not sure how that would help, but here it is:
Well, I suppose if you knew why I was asking you'd have already gotten the solution... 😉
First, the screen capture confirms that you have a structured doc.
Next, the BOOK-COMPONENT nested around the cover page file (as opposed to the one nested around the TOC) makes me suspect that your EDD isn't fully defined or that you didn't properly identify the cover page element.
How does the structure view you shared compare with your other books?
Are you able to validate the book without errors?
If the book file validates and the book structure follows the model of your other book, I'd start by defining your numbering in the para designer as using the elemnum building block to see if it resolves your issue.
With luck, you can resolve it there.
This structure is the same for all our other books. When I validate the book, it doesn't find any errors. I will have a look at using the elemnum building block, as you suggested.