PDFsharp & MigraDoc Forum
https://forum.pdfsharp.net/

Problem with bookmarks in RTF output?
https://forum.pdfsharp.net/viewtopic.php?f=2&t=2222
Page 1 of 1

Author:  jbart [ Fri Nov 16, 2012 12:27 am ]
Post subject:  Problem with bookmarks in RTF output?

Hi - I'm using MigraDoc 1.32, and have successfully generated PDF output of reasonably long (20+ pgs) documents involving text, tables, and a table of contents with hyperlinks and page references. MigraDoc/PDFsharp are working well for me! :D

But: I recently added RTF generation using an RtfDocumentRenderer - all is well there EXCEPT my Table of Contents entries look like:
1 Overview ............................................. < Please update this field. >
They do not look like this in my PDF output - the "< Please update this field. >" portion contains a page number instead.

Any suggestions as to why this is happening in RTF and not PDF generation? Thanks!

---

Follow-up note: I was able to fix this in the generated output in MS Word by right-clicking on the the "Please update this field" field and selecting "Update Field". This supplied the proper page number within MS Word for me, but this was a manual follow-on step I had to perform.

I also noticed that the page numbers I had added to my page footers were not showing up in my RTF output, but were included in my PDF output for the same document. Again, any help to fix this or explanation as to why this is happening would help. Thanks!

Author:  Thomas Hoevel [ Mon Nov 19, 2012 9:35 am ]
Post subject:  Re: Problem with bookmarks in RTF output?

With RTF files, Word makes the pagebreaks (for PDF, MigraDoc makes the pagebreaks). AFAIK you cannot get around Update Fields to show the page numbers (IIRC you have to hit Select All (Ctrl+A) and Update Fields (F9)).

Headers and footers should be in the RTF document. Again it's Word that will add the page numbers.

Page 1 of 1 All times are UTC
Powered by phpBB® Forum Software © phpBB Group
https://www.phpbb.com/