Sometimes there's a need to create instances of your own types, or other .NET Framework, non-WPF types within XAML. A classic example is a data binding value converter (which we'll explore in Chapter 6, Data Binding, but other scenarios might call for it).
Make sure you have Visual Studio 2010 up and running.
We'll create a simple application that creates an instance of a custom type in XAML to demonstrate the entire procedure:
Book. In the Solution Explorer window, right-click on the project node and select Add and then Class...:
Bookin the Name box and click on Add: