Share via


Lab 3: Working with Panels, XAML and Controls

This lab is designed to show how to work with Xaml, panels, controls, and Visual Studio’s Cider editor. You will learn the foundation of a Silverlight application’s UI.

In the lab you'll create an application to manage contacts. The application will show the data in a grid, and you’ll be able to add a new contact with a data entry form. Along the way you'll learn how to add controls with Visual Studio, work with the Cider editor, as well as how effectively use panels.

You'll start by creating a screen to view all your contacts, with the DataGrid control. Next, you’ll add a new UserControl that will be the interface to add a contact. Finally, you’ll use the StackPanel to hold the contents of a menu. The Silverlight application that you'll create is shown next:

You Will Benefit from this Lab if:

  • You are new to Silverlight
  • You are in need of a basic primer that’s business focused
  • You want to get a better understanding of how a Silverlight project is structured

You Will Learn:

  • How to use the Visual Studio 2010 Silverlight Designer, Cider
  • XAML, Panels, and Controls
  • The difference between a Grid and a StackPanel
  • How to add controls
  • XML Namespaces
  • How to create a UserControl

Business Requirements for the Silverlight application include:

  • Create a data driven interface with a DataGrid
  • Handle user interface events
  • Use XAML to create a data entry form
  • Handle the hiding and showing of the data input screen
  • Used the StackPanel to encapsulate the applications menu