StimVinsh / xdocreport

Automatically exported from code.google.com/p/xdocreport
0 stars 0 forks source link

Table of contents not updating for content not shown #126

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Run TableOfContentsTest in attached zip file
2.
3.

What is the expected output? What do you see instead?
As the developer object is null, the page headed "developers" is not shown 
which is correct. The table of contents at the top of the page does not update 
to reflect this and instead still lists developers as being on page 3.

What version of the product are you using? On what operating system?
0.9.7 with freemarker on Windows 7.

Please provide any additional information below.
It would be great if is was possible as a lot of reports I do only includes 
certain pages when lists and objects are not null.

Original issue reported on code.google.com by xnix...@gmail.com on 2 Jul 2012 at 3:59

Attachments:

GoogleCodeExporter commented 8 years ago
Hi,

This issue is the same than 
http://code.google.com/p/xdocreport/issues/detail?id=115 (it's for ODT). I'm 
afraid it's not possible. I don't know how to manage that, because table of 
content is generated by MS Word (you should refresh the table of content with 
MS Word). 

Perhaps an idea is to write macro linked to the docx which refresh the TOC (see 
http://superuser.com/questions/51268/how-to-make-a-table-of-content-auto-update)
?

Regards Angelo

Original comment by angelo.z...@gmail.com on 3 Jul 2012 at 7:18

GoogleCodeExporter commented 8 years ago
Ok thanks. Not sure I can go down the macro route as I will be doing a PDF 
conversion after the DOCX is generated. The solution I have come up with in the 
mean time is to create my own contents page and use book marks and the pageRef 
field with each line wrapped in the same if statement used to show/hide a 
particular section.

Original comment by xnix...@gmail.com on 3 Jul 2012 at 8:08

GoogleCodeExporter commented 8 years ago

Original comment by angelo.z...@gmail.com on 7 Aug 2014 at 9:01