Thursday, 29 October 2009

Code Snippets for INotifyPropertyChanged

The INotifyPropertyChanged interface is one of the mechanisms available to update WPF bindings when a property value changes.

If you work with the Model-View-ViewModel pattern, you probably implement INotifyPropertyChanged in your ViewModel classes.

To help myself create properties with support for INotifyPropertyChanged, I created a couple of simple code snippets with literal replacements for the property name and type.

Click here to download and install the snippets.

Tuesday, 6 October 2009

Step-by-step Shiny Button Template with Expression Blend 3 – Part 3


This is the third of three posts showing how to use Expression Blend 3 to create a shiny button template for WPF and Silverlight.

Part 1 Creating the static template (WPF and Silverlight)

Part 2 Adding transitions using triggers (WPF only)

Part 3 Adding transitions with the Visual State Manager (Silverlight and WPF)

In part 1 we created a static template that was applied to the button shown below:

final static button

In this part I’ll walkthrough adding different visual states and animated transitions using the Visual State Manager (VSM). I’ll be working with a Silverlight project, but the same steps should apply using the VSM with WPF.