Wednesday, October 24, 2012

VS2012 Tip of the Day: Paste XML As Classes

Rick van den Bosch - Blog - TIP: “Paste XML as Classes” in Visual Studio 2012

"In the past, when you had some XML document that you wanted to translate into classes we had to create / generate a schema based on the XML file. Next, we had to generate a class based on the schema with an external tool. Not all too user friendly and somewhat time consuming.

In Visual Studio 2012 you copy the XML you want to create a class/classes for, place the cursor in a class file on the location you want the code to be added and select the following menu items: Edit – Paste Special – Paste XML as Classes. And you’re done! Just like that…

SNAGHTMLe51c987..."

How is it that this this the first I remember seeing this feature? Added to my Hidden VS2012 Gem List (well, I don't really have such a list, but if I did, this would be on it... hum... maybe I should start one... like on a public OneNote notebook or something? Now that's an idea... )

No comments: