views:

3867

answers:

11

I've been using Winforms since .NET 1.1 and I want to start learning WPF.

I'm looking for good resources for a beginner in WPF. What should I read, what Tools I need and what are the best practices I need to follow.

+5  A: 

I'd recommend the book Windows Presentation Foundation Unleashed by Adam Nathan

Then I'd recommend you write an application. Like every other dev environment, there are no perfect guidelines. You have to find the ones that make the most sense for your circumstance. The only way to do that is to just start coding.

As for tools, Visual Studio 2008 [Express] is your best bet. Or you might be able to limp along with XamlPad.

Kevin Berridge
I've read both WPF Unleashed, as well as Teach Yourself in 24 Hours. I prefer Teach Yourself.
Alex Baranosky
+2  A: 

Visual Studio 2008 (there's a free Express version). That's all the tools you need.

Then try some How-to videos. Here's a good start: http://windowsclient.net/learn/videos_wpf.aspx

Jim Lynn
+3  A: 

Adam Nathan's - WPF Unleashed, book is very good.

RichS
+2  A: 

Microsoft actually has a decent introduction on MSDN: http://msdn.microsoft.com/en-us/library/aa970268.aspx

j0rd4n
+9  A: 

Please have a look at this StackOverflow post, which has a list of book recommendations.

In terms of best practices, get familiar with the M-V-VM pattern. It seems to have gained the most traction in WPF-land.

Check out this post for what tools you can use for WPF development.

The MSDN Forum is a great place for resources, as is the MSDN help files on WPF.

My personal recommendation is for you to forget everything you have learnt about WinForms. WPF is a totally different model, and once I finally dropped my "I did it this way in WinForms, but that way doesn't work in WPF" I had one of those "lightbulb" moments.

Hope this helps!

Brad Leach
+5  A: 
Jobi Joy
+4  A: 

I would also highly recommend using Blend together with VS 2008. Blend is great for creating animations.

The Blend 2.5 Preview can be freely downloaded.

I like the Designer WPF Blog, which has some good tutorials on how to do WPF stuff in Blend.

Ray
+7  A: 

The learning curve is high, but there are a lot of really good resources out there. And, the MSDN documentation and SDK samples (as some have already mentioned) are really good.

One thing that will help you though, is just to acknowledge the learning curve up front, and to not get discouraged when it doesn't make sense. There really are a lot of concepts to 'grok' before you can do some even basic things.

The WPF books already mentioned are all valuable in their own way. My personal experience was that I got a copy of WPF Unleashed first and tried reading it to no avail. It wasn't until I picked up Charles Petzold's Application = Code + Markup and read through some of that ... before I could even begin to understand WPF Unleashed. However, my brain needs detail before concepts actually sink in ...

Tim Sneath has an excellent list of WPF bloggers that I have found valuable to get hooked into the WPF community: WPF Bloggers

A few blogs on my must read list:

Another thing I would do is get Dr. WPF's snippet library (located here). This is an extremely good way to learn some of the basic plumbing type concepts like Dependency Properties, Routed Events, and Routed Commands.

Finally, I would get a copy of Blend (v2.5 is still in beta and free) and use that to generate xaml and then dive into that generated xaml to understand what you did in Blend, maps to the WPF API.

Hope this helps. Good luck.

cplotts
Thanks for the answer I'll look into it
Dror Helper
Charles Petzold's "Application = Code + Markup" has some nice chapters about pimping your controls. I don't remember if it was combobox or other control with subitems but there is description how to make subitems appear in circles instead of normal dropdown way. if you show this to your higher powers they will go "WOW" and shower you with money budget :)
grapkulec
+3  A: 

Although already listed above, I wanted to reiterate one point.

Kaxaml is bar none, the best loose xaml editor out there. It has a snippet library, IntelliSense, split view, a xaml scrubber (pretty print), and more.

I only wish we could hook up some assemblies (that you could reference from the xaml) ...

Robby Ingebretsen, you rock.

cplotts
+2  A: 
Alex Baranosky
+1  A: 

One resource I found that really helped me was from jfo's coding: http://blogs.msdn.com/jfoscoding/articles/765135.aspx

The document is entitled "WPF for those who know WinForms", which is exactly the position I was in last year!

pete the pagan-gerbil