System Tray Customization for Windows Phone 7

In Windows Phone 7, the System Tray is the small bar across the top of the screen and is currently used to display signal strength, current time and WiFi connection strength of your device.   This system tray can be hidden and show on command should you application require it to do so.  The following is a demonstration as to how to make this happen.

To begin, design a page with a CheckBox inside it.  This will enable the event to show or hide the System Tray.

Here is the XAML code for your reference:

<Grid x:Name="ContentPanel" Grid.Row="1" Margin="12,0,12,0" VerticalAlignment="Top">
<CheckBox Content="Show System Tray" Checked="ShowSystemTray" Unchecked="HideSystemTray"/> </Grid>

Here is the code implementation:

private void ShowSystemTray(object sender, RoutedEventArgs e)
{
 SystemTray.IsVisible = true;
}
private void HideSystemTray(object sender, RoutedEventArgs e)
{
 SystemTray.IsVisible = false;
}

When the “Show System Tray” is checked, you will see the System Tray bar at the top of the screen as shown in the first figure below:

Uncheck the “Show System Tray”. This will hide the System Tray bar from the screen.

As mentioned, this can be used to capitalize on screen real estate or can be used in situations were system notification is required.

Advertisements

2 thoughts on “System Tray Customization for Windows Phone 7

  1. Pingback: System Tray Customization for Windows Phone 7

  2. Pingback: System Tray Customization for Windows Phone 7 | Silverlight | Scoop.it

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s