My name is Salim S Salim Computer Science student. I have decided to write this tutorial because I have not seen any introductory tutorial in Window Phone 7 part in dream in code. This tutorial is going to explain the basic features in visual studio which everyone must understand in order to develop WP7 application.
This part one will only introduce how to install Visual studio and Window phone seven developer tools, the environment of Visual studio and how to run the application. The part two of this tutorial will explain files obtained in your solution and how to create the GUI and coding.
Introduction to Visual studio 2010 environment and prerequisite tools:
Microsoft visual studio, VS, is an integrated developing environment used for windows platform development. VS is fully supports the .NET Framework and some extended frameworks like silverlight and XNA which are mostly used for window phone seven development.
Where to start ;
First you need to install window phone seven developer tools from here, these tools include the following: Visual studio 2010 express (I am using VS 2010 Ultimate but I will do things which can be done in express), windows phone emulator resources, silverlight 4, XNA game studio 4.0 and MS Expression Blend.
After installation, now go to start-> All programs -> Microsoft Visual Studio 2010-> Microsoft Visual Studio 2010
1.JPG (29.69K)
Number of downloads: 10
Then click on new project as shown from the picture and the new project dialog box will appear. In the tree view select Visual c# then silverlight for windows phone and then Windows phone application. Give the name to your solution and click ok.
2.JPG (26.98K)
Number of downloads: 0
For express edition users they can see fewer installed templates. Also if you need to use XNA game studio you can select it. But for this tutorial i am going to use Silverlight as my developing framework.
Silverlight and XNA frameworks;
The Silverlight and XNA platform for windows phone 7 share some libraries, you can use some XNA libraries in a Silverlight program but you cannot create a program that mixes visuals from both platforms.
Silverlight targets applications focusing on design, presenting data and common interaction. These programs use the Extensible Application Markup Language (XAML) to define layout of user – interface controls and panels. Silverlight is great for bringing to the window phone the style of Rich Internet Applications (RIA), including media and the Web.
XNA targets visual – oriented game applications and for writing high performance games. It has high graphic performance with Direct X and the action of the game is synchronized by the built – in XNA game loop.
The different between Silverlight based applications and XNA based games is convenient but not restrictive that is you may use any of them for any development but sometimes it may be challenging.
The environment;
3.JPG (45.83K)
Number of downloads: 2
This is the windows phone seven developing environment. For those who are new in Visual studio I will show them some basic parts of this environment. The toolbar and menu bar has almost all functionality used during development like building, debugging and testing.
4.JPG (18.63K)
Number of downloads: 3
Also we have the tool box which contains tools used for creating the GUI
5.JPG (19.68K)
Number of downloads: 2
Here you can select a tool like button, textbox and progress bar by double click on it or by drag and drop. The selected tool will appear in the designing part of this environment.
6.JPG (23.47K)
Number of downloads: 2
The next thing and the important one is the solution explorer which contains the related projects and show the structure of the solution generated by windows phone application template.
7.JPG (29.15K)
Number of downloads: 1
Every file in this explorer is a part of the application which you are creating and has a special task in your application
The description of this template is as follows
8.JPG (48.17K)
Number of downloads: 1
Now you can run your application by pressing F5 key or click the start debugging tool. The windows phone emulator will open and the form will be like:
9.JPG (15.29K)
Number of downloads: 1
10.JPG (16.52K)
Number of downloads: 1
This is my application with two buttons. We will see how to write code for those buttons and more designing in part two of this tutorial but now let’s finish this tutorial by talking shortly about this emulator.
Windows phone Emulator;
This is the sample of the windows phone 7 device where by your application is expected to run in it. This device has the display of 480 x 800 pixels and in the future, screens of 320 x 480 pixels are also expected.
Also it contains a multi –touch display and three hardware buttons which are:
11.JPG (7.79K)
Number of downloads: 3 This is a back button used for navigation needs.
12.JPG (8.04K)
Number of downloads: 1 The start button used to take user to the start screen of the phone
13.JPG (7.95K)
Number of downloads: 1 Search button the OS uses it to initiate a search feature
Then you can detach the debugger and end the running session by clicking the stop button in the VS 2010 environment
14.JPG (25.13K)
Number of downloads: 1
Don’t close the emulator window, just stop debugging since it help you to reduce the time for reloading the emulator again. Also if close the emulator the debugger will raise a message to tell you that it has loose connection to the device.
15.JPG (21.01K)
Number of downloads: 1
This is the end of part one, if the moderator accept the part two we will see how to customize GUI and writing codes, also we will have a little story about windows phone 7 templates and files associated.
Thanks please rate it and for any comment don’t hesitate to post it!






MultiQuote





|