the rasx() context

I preach these Blues, then choose my seat and sit down.

Good Stuff about Brian Jones

Back in April of 2006, Brian Jones in “What about Word 2003’s XML format?” was right on the mark in his response to my comment/question about Word 2007’s programmatic support for the Word 2003 XML format. This was Brian’s response:

Great question. The range.xml property will still return the 2003 XML format. There is also a new property added called “wordOpenXML” (or something similar to that) that will return the serialized version of the Open XML format.

For C# programmers this means that:

Application.Selection.get_XML()

will return the Word 2003 XML format in Word 2003 or 2007. The new 2007 format comes from here:

Application.Selection.WordOpenXML

You may notice that the old 2003 deal is get_XML() not “range.xml” (actually/ideally Range.Xml). And this little casual oversight from Brian Jones is one of the reasons why my pathetic little attitude toward him was tinged with irriatation. He is coming from a case-insensitive VB.NET world view. Anyway, the great news is that my months of research into the 2003 format for CleanXHTML will live for at least a year more.

To leave Brian Jones in the cool, it helps to add this is not null in Word 2007:

Application.CommandBars["Menu Bar"]

Buy this book at Amazon.com!Whatever you add to this CommandBar will appear in the Ribbon in the Add-Ins Tab. This is a wonderful way to be backwards compatible but learning how to customize the Ribbon is the best way to go as you can’t guarantee that the Add-Ins Tab will be visible by default (and your menu icons will probably look horrible anyway).

Martin Parry’s “Customising the Ribbon in 2007 Microsoft Office Applications” will help her but watch this older video with a caveat. The current Ribbon support for Office Word 2007 will not a add a Tab by default. Yes, once again, VSTO SE adds Ribbon customizations to the Add-Ins Tab by default. You will see this immediately in the XML definition of the Ribbon, the tab element:

idMso="TabAddIns"

where idMso denotes the built-in name for the Add-Ins Tab. You will have to drop this attribute and then follow along with the video. It looks like adequate details (with screenshots) are available in “Customizing the 2007 Office Fluent Ribbon for Developers (Part 1 of 3).”

Share and Enjoy:
  • del.icio.us
  • Facebook
  • Technorati
  • Digg
  • Slashdot
  • Google Bookmarks

This entry was posted on Wednesday, August 8th, 2007 at 9:47 am and is filed under .NET related, Data Management Solutions, Word, root. You can follow any responses to this entry through the RSS 2.0 feed. You can leave a response, or trackback from your own site.

One Response to “Good Stuff about Brian Jones”

  1. the rasx() context » Blog Archive » Eric White is my personal replacement for Brian Jones… Says:
    July 29th, 2010 at 11:35 am

    [...] The title does sound “negative” but I’m the dude that wrote “Good Stuff about Brian Jones” in 2007. The issue here is that Eric White kicks the asses I’m thinking should be kicked—and [...]

Leave a Reply

Please leave a comment. Comments are encouraged but they must contain relevant details. These details are very helpful when they refer to exactly what the author has written. Any appeals to “common sense” with usage of phrases like, “this is stupid” or “you are so ignorant” will be ignored. Also, any quick blurbs like, “this is great” or “good job” will be reluctantly suppressed. See you later… without blindness.

the rasx() context is proudly powered by WordPress
Entries (RSS) and Comments (RSS).