Paste XML As Types: Visual Studio 2010 Extension

I used the WCF REST Starter Kit a couple of years ago to build a REST API for a project I was on, and I fell in love with “Paste XML As Types.”

I was surprised it wasn’t built into Visual Studio 2010 & I’ve wanted it on more than one occasion, so I decided to look into making a Visual Studio Extension & wanted to blog about how surprisingly easy it was.

In this article, Danny Diaz explained how to convert the VS 2008 feature to an installable VS 2010 addin.

After following those instructions, I was shocked at how easy it was to create a VSI. It was literally a matter of zipping the dll, & the .AddIn file, then changing the .zip extension to .VSI. (I know there are many signing steps that can take place but I was looking for a quick & easy way to get that functionality into Visual Studio 2010 in all of my environments without having to reinstall the REST Starter Kit msi.)

Poof! It worked! I installed it into Visual Studio by simply double-clicking on it.

I wanted to make this into a Visual Studio Extension & upload it to the gallery, but according to this article, “The VSIX format does not support the installation of macros, add-ins, or code snippets.”

If you know of a way around this, please let me know.

In the meantime, feel free to give my vsi a try if you miss “Paste Xml As Type” in VS 2010 as much as I did:

http://dl.dropbox.com/u/24179695/PasteXmlAsType.vsi

Enjoy!

2 Comments on “Paste XML As Types: Visual Studio 2010 Extension”

  1. Khaled Sliman Says:

    This just screwed up my VS, now any time I try to access the edit menu or even ctrl-v VS just hangs. This was a bad idea.

    Reply

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: