Bookmark in Word buildingblocks disappear in Open XML Glossary part of a template

Peter Karlström 216 Reputation points
2020-09-21T10:49:12.773+00:00

Hi
We have a Word template file with some predefined header and footer parts saved as building blocks in the template.
When we use this template in our Word Add In application it behaves as expected.
But if we try to use the building blocks on our Open XML service, some of the bookmarks are missing. After some digging around in the templaqte we found that Word does not handle the content och the building block correctly in the resulting XML file.
Using Open XML Productivity Tool , we found that the in Glossary part of the document, some of our bookmarks is missing.
When we open the same file in word and insert the building block, the bookmark is there as expected.

Why is this? It is very frustrating and we have tried replacing the faulty parts in every possible way but without success.
What is wrong here?

Regards Peter Karlström

Microsoft 365 and Office | Word | For business | Windows
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Peter Karlström 216 Reputation points
    2020-09-21T21:36:22.267+00:00

    Hello @John Korchok

    Thank you for your reply.

    You are correct when you say you beleive it is Autotext entries I talk about.
    The Autotext entries are located in the template itself and not in a global template.
    All items and bookmarks in the Autotext entry is found in Open XML Productivity Tool except for one of the bookmarks which is missing.

    The items and text in the Autotext entry is organized in a table.
    The bookmark in question is located to the left in the first and uppermost cell.
    There are 4 similar Autotext entries in the template, and 2 of them are OK but in 2 of them this first bookmark is missing.
    Note that the bookmarks only is missing when examining the document with Open XML Productivity Tool and not in Word when you insert the autotext entry directly in the opened template or in a document created from the template.

    Does this give you more hints about the problem

    Regards
    Peter


Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.