I have a content control like this
SdtBlock xSdtBlock = (SdtBlock)contentcontrol; SdtProperties sdrprops = xSdtBlock.Descendants<SdtProperties>().FirstOrDefault();
How do I add an element inside of that? The element I want to add is
<w15:appearance w15:val="hidden"/>
so that the xml block looks like
<w:sdtPr>
<w:rPr>
<w:lang w:val="en-GB"/>
</w:rPr>
<w:alias w:val="TitleTest"/>
<w:tag w:val="TagTest"/>
<w:id w:val="1500618722"/>
<w:temporary/>
<w:showingPlcHdr/>
<w15:appearance w15:val="hidden"/>
<w:picture/>
</w:sdtPr>
instead of current
<w:sdtPr>
<w:rPr>
<w:lang w:val="en-GB"/>
</w:rPr>
<w:alias w:val="TitleTest"/>
<w:tag w:val="TagiTest"/>
<w:id w:val="1500618722"/>
<w:temporary/>
<w:showingPlcHdr/>
<w:picture/>
</w:sdtPr>
I'm trying to accomplish the same that what can be done in Word by setting content control properties "Show as" to "None" instead of "Bounding Box" so that the placeholder image wouldn't be displayed anymore.