WPF (Windows Presentation Foundation) supports developing the applications similar to Windows Form Applications as well as with XAML based environment i.e. flexibility is available to create with XAML support and with normal traditional windows forms support.
Application Development in WPF
Application development in WPF is scattered into 5 areas:
Windows Based Desktop Applications.
Navigation Applications.
XAML Browser Applications (XBAPs)
Custom Control Libraries.
Class Libraries.
Working with Windows Based Application
Windows based desktop applications are very much similar to windows forms applications.
Complete class library related to WPF is available in System.windows namespace.
Creating WPF Application
Step-1
First open "Visual studio".Click on File-> New -> Project
Step-2
Double click on Visual C# from installed templates.Select the WPF application->Type the Application Name ->Click on OK.
Step-3
After click on ok, then the WPF application is created. The application becomes like below screen:
More Info
Every WPF Application will contain some set of user interfaces called Windows.
In every window, within WPF application, a class can be created and it is inherited from System.windows.window class.
For every window created, there are two files associated within Solution Explorer.
.XAML
XAML.CS
.XAML:
Description
.XAML is very much similar to .aspx file in asp.net.This file will contain two parts.One is Design part and another one is Source part.
Source part contains XAML design code for creating the user interface elements.
Design part will contain the respective physical appearance for the design code.
.XAML.CS
Description
.XAML.CS is similar to .aspx.cs file in asp.net and this will contain complete programming part code.
In general, there is a hierarchy maintained within the window like below: