locked
WORD 2010 strip out the xml tags RRS feed

  • Question

  • I cant able to view custom XML tags in word 2010. The docx file is created in Word2007 and when i try to open it in 2010. it removes all the tags and just shows a text..

    Please help me to solve this problem

     

    Regards,

    Antony.

    Monday, September 6, 2010 6:14 AM

Answers

  • Hi Antony

    The problem is that this functionality was removed in Office 2010. A Canadian company (i4i) sued Microsoft in a patent case. The court decision came out a year ago and Microsoft lost. I understand they've appealed to the Supreme Court, but for the moment they aren't allowed to use the technology introduced in Office 2003 for working with XML "tags" on the document surface.

    Those tags are actually still in the document when it's opened, but are inaccessible to the object model and the UI. When the document is saved, they're stripped out completely. This is done without warning.

    A transform (XSLT) executed when the document is opened will still work. The schema remains attached. Custom XML tags can still be added to a document while it's open in the UI and will be saved (but lost again on re-open).

    Word 2003 *.doc files containing these tags remain intact. The decision affects only *.docx file format.

    For more information, see Gray Knowlton's blog:

    http://blogs.technet.com/b/gray_knowlton/archive/2009/12/23/what-is-custom-xml-and-the-impact-of-the-i4i-judgment-on-word.aspx
    http://blogs.technet.com/b/gray_knowlton/archive/2010/01.aspx


    Cindy Meister, VSTO/Word MVP
    • Marked as answer by Amy Li Friday, September 10, 2010 8:29 AM
    • Unmarked as answer by Cindy Meister MVP Friday, September 10, 2010 3:52 PM
    • Marked as answer by Bessie Zhao Monday, October 11, 2010 9:55 AM
    Monday, September 6, 2010 7:05 AM

All replies

  • The docx format is not an XML document but a zip file that contains a variety of XML modules to make up a whole that is translated to the finished document by Word. You can open the docx  envelope using WinRar or WinZip and extract the XML modules and you can edit them as text files in Word, but you will need a thorough understanding of the document structure if you plan to make changes to the XML code it contains or you will end up with a document that Word will not be able to open.

    <A-N-T-O-N-Y> wrote in message news:10fe3eaa-d6c2-4763-aa84-e57164cec96d@communitybridge.codeplex.com...

    I cant able to view custom XML tags in word 2010. The docx file is created in Word2007 and when i try to open it in 2010. it removes all the tags and just shows a text..

    Please help me to solve this problem



    Regards,

    Antony.


    Graham Mayor - Word MVP
    www.gmayor.com
    Posted via the Communities Bridge
    http://communitybridge.codeplex.com/
    • Marked as answer by Amy Li Friday, September 10, 2010 8:29 AM
    • Unmarked as answer by Cindy Meister MVP Friday, September 10, 2010 3:52 PM
    Monday, September 6, 2010 6:41 AM
  • Hi Antony

    The problem is that this functionality was removed in Office 2010. A Canadian company (i4i) sued Microsoft in a patent case. The court decision came out a year ago and Microsoft lost. I understand they've appealed to the Supreme Court, but for the moment they aren't allowed to use the technology introduced in Office 2003 for working with XML "tags" on the document surface.

    Those tags are actually still in the document when it's opened, but are inaccessible to the object model and the UI. When the document is saved, they're stripped out completely. This is done without warning.

    A transform (XSLT) executed when the document is opened will still work. The schema remains attached. Custom XML tags can still be added to a document while it's open in the UI and will be saved (but lost again on re-open).

    Word 2003 *.doc files containing these tags remain intact. The decision affects only *.docx file format.

    For more information, see Gray Knowlton's blog:

    http://blogs.technet.com/b/gray_knowlton/archive/2009/12/23/what-is-custom-xml-and-the-impact-of-the-i4i-judgment-on-word.aspx
    http://blogs.technet.com/b/gray_knowlton/archive/2010/01.aspx


    Cindy Meister, VSTO/Word MVP
    • Marked as answer by Amy Li Friday, September 10, 2010 8:29 AM
    • Unmarked as answer by Cindy Meister MVP Friday, September 10, 2010 3:52 PM
    • Marked as answer by Bessie Zhao Monday, October 11, 2010 9:55 AM
    Monday, September 6, 2010 7:05 AM
  • Hi Antony,

    How is this issue going on in your side? Have you solved the problem?

    Best Regards,
    Amy Li
    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.
    Friday, September 10, 2010 3:19 AM
  • Hi Antony,

    I will mark the answer for the thread. Any further questions, please feel free to follow up. Thank you!

    Best Regards,
    Amy Li
    Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.
    Friday, September 10, 2010 8:28 AM