Nathan Black SDE Microsoft Session Code: WEM203 Overview of WPF Windows Presentation Foundation UI Framework Introduced in .NET 3.0 Rich UI Development Using Extensible Application Markup Language.

Download Report

Transcript Nathan Black SDE Microsoft Session Code: WEM203 Overview of WPF Windows Presentation Foundation UI Framework Introduced in .NET 3.0 Rich UI Development Using Extensible Application Markup Language.

Nathan Black
SDE
Microsoft
Session Code: WEM203
Overview of WPF
Windows Presentation Foundation
UI Framework Introduced in .NET 3.0
Rich UI Development Using Extensible
Application Markup Language (XAML)
Clear Separation of Design and Business Logic
WPF/e Used in Silverlight
What is XAML?
The XML language used to create
WPF Applications
Declarative rather than procedural
XAML gets compiled into an object definition
Anatomy of a XAML File
<Window
xmlns="http://schemas.microsoft.com/winfx/2006/xaml/p
resentation"
x:Class="AirportKiosk.Window1"
x:Name="Window" Title="Window1"
•
Width="640" Height="480">
<Grid x:Name="LayoutRoot">
Main
<Grid Width="100" Height="100">
Window
<Button Content="Hello">
<Button.Background>
<Brush>Orange</Brush>
Layout Grid
</Button.Background>
</Button>
Individual Controls
</Grid>
(Button)
</Grid>
</Window>
Code Behind
Event declared in XAML
Logic implemented in a code-behind file (C#,
VB.NET, or any other .NET language)
<Button Content="Hello" x:Name="Button1"
Click="Button1_Click">
<Button.Background>
<Brush>Orange</Brush>
</Button.Background>
</Button>
Code Behind (continued)
public partial class Window1
{
public Window1()
{
// Load our component from XAML
InitializeComponent();
}
public void Button1_Click(object sender,
RoutedEventArgs e)
{
MessageBox.Show("Hello!");
}
}
Data Binding
Binding Target
Dependency Object
Dependency
Property
Binding Source
One Way
Two Way
One Way To
Source
Object
Property
XAML UI can be bound to CLR objects or XML
Properties can also be bound to ADO.NET
and objects associated with Web Services
and Web Properties
Sort, filter and group views can be generated
on top of the data
Data Templates
<ListBox ItemsSource="{Binding
Source={StaticResource photos}}" …>
<ListBox.ItemTemplate>
<DataTemplate>
<Image Source="{Binding Path=FullPath}"
Height="30"/>
</DataTemplate>
</ListBox.ItemTemplate></ListBox>
Leveraging WPF for Embedded Devices
Perfect for applications where UI is key
ATM
Kiosk
Point of Sale
Jukebox
The Silverlight Option
Very small footprint for small devices
Deployment and servicing is simplified
Tradeoffs when in the browser
Expression Blend
Nathan Black
SDE
Microsoft
Quebec Image Building Concepts
EEF Package
Embedded Core
(Bootable)
Enhanced
Write Filter
Feature Packages
Internet
Explorer
Update Package
Lang Packs/
Driver Packs
Image-Based
Setup on the device
Embedded
OS
3rd Party
Software
Installer
OS Updates
About the Toolkit
The toolkit provides a rich set of utilities to help
support the development lifecycle of an Embedded
Windows OS
Analysis of target machine
Configuration of embedded run-time image
Building of embedded run-time image based
on configuration
Online tweaking and testing of embedded run-time
Capture of final embedded run-time image to be deployed
Deploy captured image to many devices
Based on the Windows AIK/OPK
WES 2009 vs. Quebec
Process
Windows
Embedded
Standard (WES)
Quebec
Analysis
TAP.exe generates a
.PMQ File
TAP.exe generates a
PMQ File (same file as
WES)
Configuration
Use Target Designer to
create a configuration
file (SLX)
Use Image Configuration
Editor (ICE) to create an
answer file
Run-time Image Build
Image build happens on
the developer machine
using Target Designer
Image build happens on
the reference/target
device using Image
Builder Engine
WES 2009 vs. Quebec
Process
Windows
Embedded
Standard (WES)
Quebec
Resource Management
SQL DBM
File-based repository
Custom Resources
Component Designer
Use ICE to generate
answer file with Data
Image, $OEM$ Folders,
and scripting
Image Capture
Fbreseal
SDI
Sysprep
ImageX
Image Configuration Editor (ICE)
IDE-type application
Enables scripted build and installation through image builder
engine
Provides advanced functionality
Ability to configure settings
Ability to script installation of 3rd party applications
Search and dependency resolution
1.Install
2.Configure
3.Save
4.Build & Install
ICE
Distribution Share Interface
Answer
File
Image Builder Engine
(On the device)
Shell Launcher
Embedded devices are task-centric
The one application should be all they want
Replacing the shell previously required
registry editing
Shell Launcher provided as a simple way to do
this common task
Simple setting apart of
Embedded Enabling Features (EEFs)
Configuring the Kiosk Image Using ICE
Nathan Black
SDE
Microsoft
Airport Kiosk
Nathan Black
SDE
Microsoft
Windows Embedded Resources
Website:
www.windowsembedded.com
Social Channels:
blogs.msdn.com/mikehall
blogs.msdn.com/obloch
Technical Resources:
http://msdn.microsoft.com/embedded
Tools evaluations:
www.windowsembedded.com/downloads
Related Content
ARC310 Building Modular Applications Using Microsoft Silverlight and WPF
WUX204 Building Rich Business Clients in WPF: Building Data Visualization
Applications with the Windows Presentation Foundation
WUX304 Building Rich Business Clients in WPF: New Tools and Controls for Windows
Presentation Foundation
WUX305 Building Rich Business Clients in WPF: Getting the Most Out of Windows
Presentation Foundation
WEM04-HOL Develop and Deploy a WPF Shell for Windows Embedded Standard 2009
WEM07-HOL Using WPF and Microsoft POS for .NET to Create an Application for
Windows Embedded POSReady 2009
DTL03-HOL Data-centric WPF Applications
Resources
www.microsoft.com/teched
www.microsoft.com/learning
Sessions On-Demand & Community
Microsoft Certification & Training Resources
http://microsoft.com/technet
http://microsoft.com/msdn
Resources for IT Professionals
Resources for Developers
www.microsoft.com/learning
Microsoft Certification and Training Resources
Complete an
evaluation on
CommNet and
enter to win!
© 2009 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries.
The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should
not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS,
IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.