I. Download the Windows Phone SDK
System Requirements
- Supported operating systems:Windows 7; Windows Vista
- Windows Vista (x86 and x64) Service Pack 2-All versions except Starter Edition
- Windows 7 (x86 and x64)-All versions except Starter Edition
- The installation requires 4 GB of available disk space on the system drive.
- 3 GB memory
- Windows Phone emulator requires the wddm 1.1 driverProgramSupports graphics cards of DirectX 10 or later versions.
Note: Windows Phone SDK 7.1 is compatible with the final version of Visual Studio 2010 SP1.
If your computer is installed with a pre-release version (Beta or RC) of Windows Phone SDK 7.1, uninstall the version before installing the product.
:
Chinese version:Http://download.microsoft.com/download/7/E/C/7EC8F134-0CCF-4741-8BB0-2BABE4FC4875/WPSDKv71_chs1.iso
Http://go.microsoft.com/fwlink? Linkid = 226694
The Windows Phone SDK includes the following components:
- Microsoft Visual Studio 2010 learning edition for Windows Phone
- Windows Phone emulator
- Windows Phone SDK 7.1 assembly
- Silverlight 4 SDK and DRT
- Windows Phone SDK 4.0 extension for xNa game studio 7.1
- Microsoft Expression blend SDK for Windows Phone 7
- Microsoft Expression blend SDK for Windows Phone OS 7.1
- WCF Data Services Client for Windows Phone
- Microsoft advertising SDK for Windows Phone
Ii. Installation The installation process is simple and will not be described here
3. Write the first WP7 Program
- Start visual studio2010 and create a project
- WriteCode
The function we want to implement here is to click a button to change the text of pagetitle, so the code we want to modify is as follows:
1 <Stackpanel X: Name = " Titlepanel " Grid. Row = " 0 " Margin = " " >
2 <Textblock X: Name = " Applicationtitle " TEXT = " First Windows Phone " Style = " {Staticresource phonetextnormalstyle} " />
3 <Textblock X: Name = " Pagetitle " TEXT = " Hello Windows Phone " Fontsize = " 38 " Margin = " 9,-7, 0, 0 " Style = " {Staticresource phonetexttitle1style} " />
4 <Button X: Name = " Btnclick " Content = " Click to change title " Click = " Btnclick_click " />
5 </Stackpanel>
Compile events for buttons:
Private VoidBtnclick_click (ObjectSender, routedeventargs E)
{
Pagetitle. Text ="Learn WP7 development with limits!";
}
Run the F5 simulator. The effect is as follows:
Effect after clicking the button: