New XML Mapping tool for Word developers

Today's post is guest written by Tristan Davis, a program manager on the Word team.

As part of the Word team, one of the things I'm responsible for is extensibility. In that role, I've had the opportunity to see how Word developers are building solutions on top of our object model, and to hear a lot of valuable feedback about the good and bad aspects of building them.

A large number of these solutions utilize Word to create rich, structured documents through the use of content controls and XML mapping. These features are really popular because they allow developers to quickly display and extract business data within Word documents (see the bottom of the post for some introductory links if you haven't used them before).

Many of you, though, have asked for a faster way to set up mapped content controls - something that's user-interface-based and can be done right within Word, without having to resort to code or Open XML manipulation.

To that end, I'm really excited to announce the release of the XML Mapping Task Pane project on CodePlex at http://xmlmapping.codeplex.com.

What is the XML Mapping Task Pane?

This add-in gives developers a task pane in Word for working with XML parts and mapping them to content controls within the document. Once installed, it creates a Mapping group on the Developer tab. Click the XML Mapping button within it and the XML Mapping task pane opens:

 XML Mapping task pane

From the task pane, you can perform all of the tasks necessary to set up a document with mapped content controls:

  • Add XML parts to the document, both from an existing XML file or by directly entering its content
  • See the list of XML parts available in the document
  • View the contents of each part as a tree
  • Drag and drop XML nodes into the document to create mapped content controls
  • Map existing content controls to a specific XML node via a right-click menu

The task pane provides access via the UI to functionality that exists today - offering developers a faster way to perform those functions.

The add-in isn't supported by Microsoft, but its source code is available on the CodePlex site for you to view/edit/reuse/enhance - I'd love to hear your feedback there, so please do give it a try.

 Thanks!

--Tristan

P.S. Introductory links for content controls

Here are a few links I'd recommend if you're new to content controls, and would like to learn more:

Office Blogs Comments

Comments: (3) Collapse

  • I am getting a download error on vsto file when trying to install.

  • Hi David,

    Sorry to hear that - can you send me a message with the details of the error (or even better, log an issue on the CodePlex site) so we can take a look?

    Thanks!

  • There is still problem using this tool as download/install gives error for Xml Mapping Task Pane.vsto. Furthermore even if the tool is first unblocked and then run on some machines it gets quarantined by the Symantec tool.

    Codeplex discussions are not observed – please help!

Comments

Comments: (loading) Collapse