June 16, 2011

This sample demonstrates how to update an Application Tile using the ShellTile APIs. It also demonstrates how to create, delete, and update secondary Tiles. For more information about using Tiles, see Tiles Overview for Windows Phone. For a walkthrough of creating this sample application, see How to: Create, Delete, and Update Tiles for Windows Phone.

You need to install Windows Phone SDK 7.1 Beta 2 to run this sample. To get started, go to App Hub.

To run the sample

  1. Double-click TileSample.sln to open the solution.

  2. Press F5 to start debugging the application.

  3. When the application launches in Windows Phone Emulator, the initial page shows two buttons, one for updating the Application Tile and one for creating, updating, and deleting the secondary Tile.

  4. Click the button to navigate to the Application Tile properties page. Set some properties and then click the button to set the properties. Valid names for background image files are Red.jpg, Blue.jpg, and Green.jpg.

  5. Navigate out of the application to the Application List. Pin the TileSample Application Tile to Start. It should be updated to the properties that you set.

  6. Tap the TileSample Application Tile to re-enter the application. Navigate to Secondary Tiles page. It shows a check box and six text box and button pairs for setting the various properties of a Tile.

  7. Select the check box to create a secondary Tile on Start. Windows Phone Emulator will automatically navigate to Start, where you can see the Tile.

  8. Navigate back to the application. Try setting various values for the Tile properties by filling in a value and clicking the corresponding button. Valid names for background image files are Red.jpg, Blue.jpg, and Green.jpg. After setting a value, you have to navigate back to Start to see the result.