June 16, 2011
This sample demonstrates how to send a Tile notification to a Windows Phone using the Microsoft Push Notification Service. This sample contains two projects – one project for the client code that sets up the Windows Phone device to receive a notification, and another project that sends the notification to the Microsoft Push Notification Service.
For more information about Push Notifications, see Push Notifications Overview for Windows Phone. For a walkthrough of creating this sample application, see How to: Send and Receive Tile Notifications 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.
The project that sends a Tile notification from an ASP.NET webpage running on a web server requires either the full version of Visual Studio or the free Microsoft Visual Web Developer 2010 Express.
To run the sample
After unzipping the sample, note that there are two projects.
Double-click TileNotificationClient.sln to open the solution.
Press F5 to start debugging the application.
When the application launches in Windows Phone Emulator, there will be a brief pause and then a message box containing the notification channel URI will appear. Close the message box. The URI also will be displayed in the Visual Studio debugger Output window.
Copy this URI from the Visual Studio debugger Output window to the clipboard.
In Windows Phone Emulator, navigate to the application list and pin the Tile for the TileNotificationClient to Start.
Now find SendTile.sln and open it with a full version of Visual Studio or the free Microsoft Visual Web Developer 2010 Express.
Press F5 to start debugging the application.
A webpage will open. Paste the notification channel URI into the URI text box on the webpage.
Enter a couple of values for the Tile and press the Send Tile button. Valid names for background image files are Red.jpg, Blue.jpg, and Green.jpg.
After a brief pause, the TileNotificationClient Tile that was pinned to Start will update.