WPF Through an Example: Introduction
(Page 1 of 4 )
The Windows Presentation Foundation enables you to enhance the user experience of your Windows Forms application. You'll see how effortlessly you can add advanced graphical features and more with WPF. In this four-part series, we'll walk you through the basics of WPF by showing you how to create a simple application and make it appealing to use.
Developing Windows client applications with Windows Forms can sometimes get a bit dull. The mode of development contrasts sharply with technologies such as ASP.NET, which enable the developer to declaratively define the layout of an application, separating presentation from logic. Adding special features to a Windows Forms application involves bringing in (and learning to use) other technologies. As a result, the user experience often suffers. At a time when many Web applications aim at offering a “rich” user experience filled with all sorts of bells, whistles and eye candy, Windows Forms applications seem a bit obsolete.
This is where the Windows Presentation Foundation, or WPF, comes to the rescue. WPF offers a new way to build Windows applications that offer the user a richer experience. WPF applications offer the user advanced graphical features, animation, multimedia components, a better look and integration with documents, among other features, and the great part is that none of this places a large burden on the developer.
In fact, development becomes much easier. Developers of WPF applications can now declaratively define the appearance of an application with Extensible Application Markup Language (XAML), and can implement the mechanics of an application in a code-behind file, separating presentation from logic in a way similar to what is done in ASP.NET. This approach also makes applications easier to divide up: designers can work with the visual half of the application using tools such as Microsoft Expression, and developers can work with the programming half using Visual Studio. The two halves can then be easily combined to form a visually pleasing product.
Moreover, while WPF provides a way to create traditional Windows applications, many users may prefer a browser-based experience. Because of this, WPF also offers a way to create browser-hosted applications, where the application will open in the user's browser rather than a traditional desktop window. Furthermore, Silverlight is compatible with WPF, and so knowledge of WPF in building Windows applications will carry over to building Silverlight applications.
In this series of articles, we'll take a look at some of the technologies offered by WPF. You'll learn the basics of WPF by constructing a simple application: a to-do application that allows the user to manage a list of tasks. A list of tasks will be loaded from an XML file and then presented to the user in an appealing way. Tasks will be named and will feature descriptions, and each task will be assigned a priority. When a task is complete, the user can mark it as being done. New tasks can be added by the user, and existing tasks can be deleted.
This example project will provide a general introduction to WPF and then allow progression to more advanced features.
Next: Creating a WPF Project >>
More Windows Scripting Articles
More By Peyton McCullough