none
Getting the WordOpenXML from a control inside a table RRS feed

  • Question

  • Hello,

     

    Today I found something strange. I have uploaded a screen-cast. Here is the link: http://www.damp.ro/fisiere/stange-clipboard-behavior-for-tables-swf/265395/XM0MmjIXk3iAVOEl

     

    The problem is that the clipboard seems to change when I try to get the WordOpenXML value from a building block gallry control that is inside a table.

    Does anyone have a clue why? Can some reproduce it on their PC?

     

    I am using Office 2007 and VSTO 3.0. You only need to create a Word 2007-AddIn and simply attack to the ContentControlOnExit event and add this line of code:

    string value = ContentControl.Range.WordOpenXML;
    


    Add a brakepoint on that line of code. Add in the watch System.Windows.Forms.Clipboard.GetText() . See the value of the clipboard before and after.

    PS: The pasted control is the document is a buildingBlock gallery ContentControl (BBG1). Inside it there is a Table. Inside the table put in one of the cells a building block gallery ContentControl (BBG2).

     

    Best regards,

    Silviu.


    http://www.rosoftlab.net/
    Thursday, November 3, 2011 10:42 AM