WPF/E: Setting up your workstation for development

So you've installed the WPF/E runtime and played with a few samples.  You've probably also installed the WPF/E SDK and opened up some of the sample source code.  What next?  Write your own WPF/E code, of course! 

Adam Kinney has posted a video on Channel 9 about Getting Started with WPF/E. It's worth a listen (I say listen because the code on his screen is illegible, but it's interesting anyway).  In this video he opens up a WPF/E project template and uses that as a starting point.  So where is this template and how can you get it?  Well, there's a hard way and an easy way to get it ...

The Hard Way

silverlight-template-menu If you've installed the WPF/E SDK there is a link in there's a link in your Start Menu which should look like the image to the right.  This links to an installer which will get the WPF/E project template loaded.

Not too hard, you think?  Well it's not that simple.

This installer requires some additional Visual Studio bits.  Specifically you need to download and install the following:

This is a bit of a bother as it will affect your Visual Studio installation outside of your WPF/E development.  But if you liked the VS2003 web projects and you miss them then go ahead.

The Easy Way

Project templates are really just specially constructed zip files and Visual Studio 2005 has a special folder where you can add your own.  This is configured on Tools / Options / Projects and Solutions, but it defaults to "[My Documents]\Visual Studio 2005\Templates\ProjectTemplates".  So if you go to this folder, open up the "Visual C#" folder (or whichever sub-folder you prefer) you can copy in the project template which I've attached to this post.  Then you'll get the WPF/E template showing up in your New Project window as follows without installing anything else:



EDIT [2006-12-06]: I've modified the attached template for:

EDIT [2006-12-08]: I modified the namespace back to http://schemas.microsoft.com/client/2007.  Once you've copied the wpfe.xsd file correctly, Visual Studio will then give you Intellisense.  See my next post for more info.

December 5 2006
blog comments powered by Disqus