Inserting a text content control and then binding to it in Word RRS feed

  • Question

  • I am attempting to manually build an OOXML word document package with some text inside rich text content controls and then bind to it using addFromNamedItemAsync.

    I have called the tag for the rich text content control "test1" (  <w:tag w:val="test1"/>).

    The rich text content control is visible in the document when I insert it using setSelectedDataAsync, but when I try to bind after a successful insert, I get the error "the named item does not exist."

    Is there anything else that I need to add to this XML for addFromNamedItemAsync to find it? Thanks!

    The relevant XML looks like this:


                         <w:tag w:val="test1"/>
                               <w:pStyle w:val="Heading1" />
                               <w:jc w:val="center" />
                                  <w:color w:val="000000" w:themeColor="text1" />
                                  <w:sz w:val="44" />
                                  <w:color w:val="000000" w:themeColor="text1" />
                               <w:t>testing123 text</w:t>
                   <w:sectPr w:rsidR="00000000">
                      <w:pgSz w:w="12240" w:h="15840" />
                      <w:pgMar w:top="1440" w:right="1440" w:bottom="1440" w:left="1440" w:header="720" w:footer="720" w:gutter="0" />
                      <w:cols w:space="720" />

    Thursday, June 18, 2015 6:57 PM