Disable docx toc update
-
Version: 4.10.1 (single file executable)
Hello,
as I understand from the documentation, if jsreport detects a table of content, it automatically tries to update this. As good as an automated update would be, this seems to be a bit hacky and is not working properly for my template. My solution would be to just not use page numbers and to keep the toc as it is in the template, because there is no generated headings. However I do not seem to find a way that the toc just stays the same as in the template. I tried setting {{docxTOCOptions updateFields=false}} in the table header but this did not work. Is there any solution for this?Thank you!
-
hi @bjarnesc
as I understand from the documentation, if jsreport detects a table of content, it automatically tries to update this. As good as an automated update would be, this seems to be a bit hacky and is not working properly for my template.
maybe we can try to fix the automatic update for your template. if you share your entities we can take a look.
My solution would be to just not use page numbers and to keep the toc as it is in the template, because there is no generated headings. However I do not seem to find a way that the toc just stays the same as in the template. I tried setting {{docxTOCOptions updateFields=false}} in the table header but this did not work. Is there any solution for this?
no way to disable the automatic sync of TOC, the
updateFields
is an option for another purpose, it is described in the docs. i have opened a new issue to add an option to disable the automatic sync, you can subscribe there for updates.
-
Thank you @bjrmatos for the quick answer. An option to disable this would be super! I cannot share the full entities, because it contains customer information but I will maybe try to recreate a stripped version in the next days.
-
@bjarnesc yes, let us know if you get to have a sample ready