Latest

random

C# - Wpf Sample Application

WPF Tutorial for Beginners

WPF stands for Windows Presentation Foundation, which is the Microsoft's latest and most advanced approach to a GUI (Graphical User Interface) framework with .Net. It is the development platform of choice for desktop applications and Windows 8 and all previous versions of Windows. 

WPF uses the declarative language XAML in WPF Application, so It's a combination of XAML mark-up language and C#/VB.Net/any other .Net language.

Top 5 WPF Features 

WPF comes with lots of advantages. Let me introduce a few of its features :-
  1. WPF is Resolution Independence

  2. WPF separates the appearance of an UI from its behaviour. The appearance is specified by XAML and behaviour is specified by a managed programming language like C# or VB. Net

  3. WPF applications run within DirectX environment, It has graphics and animation capabilities. 

  4. WPF has support for playing any audio or video file supported by Windows Media Player.

  5. Highly Customizable. WPF supports separation of appearance and behaviours; hence you can easily change the look of a control or a set of controls. This concept of styling controls in WPF, is almost like CSS in HTML. In WPF, you can store styles, controls, animations, and even any object as a resource and you may associate that resource to the controls. Each resource is declared once when the form loads itself.

Hello World - WPF Sample Application C#

In this article I will give you a quick demo of hello world wpf application demo for beginners. A basic knowledge of C# is recommended when learning to use WPF. By creating a new project in Visual Studio, from the templates choose Visual C#, over in the list of actual templates choose WPF application. After visual studio settles down, we open up in MainWindow.xaml

wpf project, wpf app,desktop application, wpf
Wpf Application for Beginners
It is the principle or first window that is created for you, there are a number of other files like App.config and App.xaml files. Find the code below :-

wpf, wpf controls, wpf application, wpf features, wpf interview questions, wpf example, wpf tutorials, wpf tutorial for beginners, wpf samples, wpf sample application
Wpf Sample Application Demo
MainWindow.xaml
<Window x:Class="HelloWPF.MainWindow"
        xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
        xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
        Title="WPF Demo" Height="350" Width="525">
    <Grid>
      <TextBlock x:Name="Hello"
                 Text="Hello World!" /> 
    </Grid>
</Window>
I hope you will enjoy the development tips while programming with WPF. I would like to have feedback from my blog readers. Your valuable feedback, question, or comments about this article are always welcome. 

Also If you like this article, don't forget to share this article with your friends and colleagues.

No comments:

All Rights Reserved by Etechpulse © 2015 - 2016
Powered By Blogger

Contact Form

Name

Email *

Message *

Powered by Blogger.