2 out of 4 rated this helpful - Rate this topic

ProgressIndicator Class

July 26, 2012

Provides methods and properties for interacting with the progress indicator on the system tray on an application page.

System.Object
  System.Windows.DependencyObject
    Microsoft.Phone.Shell.ProgressIndicator

Namespace:  Microsoft.Phone.Shell
Assembly:  Microsoft.Phone (in Microsoft.Phone.dll)
XMLNS for XAML: Not mapped to an xmlns.
public class ProgressIndicator : DependencyObject
<ProgressIndicator .../>

The ProgressIndicator type exposes the following members.

  NameDescription
Public methodProgressIndicatorCreates a new instance of the ProgressIndicator class.
Top
  NameDescription
Public propertyDispatcher (Inherited from DependencyObject.)
Public propertyIsIndeterminateGets or sets a value that indicates whether the progress indicator on the system tray on the current application page is determinate or indeterminate.
Public propertyIsVisibleGets or sets the visibility of the progress indicator on the system tray on the current application page.
Public propertyTextGets or sets the text of the progress indicator on the system tray on the current application page.
Public propertyValueGets or sets the value of the progress indicator on the system tray on the current application page.
Top
  NameDescription
Public methodCheckAccess (Inherited from DependencyObject.)
Public methodClearValue (Inherited from DependencyObject.)
Public methodEquals (Inherited from Object.)
Protected methodFinalize (Inherited from Object.)
Public methodGetAnimationBaseValue (Inherited from DependencyObject.)
Public methodGetHashCode (Inherited from Object.)
Public methodGetType (Inherited from Object.)
Public methodGetValue (Inherited from DependencyObject.)
Protected methodMemberwiseClone (Inherited from Object.)
Public methodReadLocalValue (Inherited from DependencyObject.)
Public methodSetValue (Inherited from DependencyObject.)
Public methodToString (Inherited from Object.)
Top
  NameDescription
Public fieldStatic memberIsIndeterminatePropertyThe dependency property for IsIndeterminate.
Public fieldStatic memberIsVisiblePropertyThe dependency property for IsVisible.
Public fieldStatic memberTextPropertyThe dependency property for Text.
Public fieldStatic memberValuePropertyThe dependency property for Value.
Top

The system tray is also referred to as the status bar.

The following code example shows how to use the ProgressIndicator class.

using Microsoft.Phone.Shell;

namespace SystemTrayTest
{
    public partial class MainPage : PhoneApplicationPage
    {
        ProgressIndicator prog;

        public MainPage()
        {
            InitializeComponent();

            SystemTray.SetIsVisible(this, true);
            SystemTray.SetOpacity(this, 0.5);
            SystemTray.SetBackgroundColor(this, Colors.Purple);
            SystemTray.SetForegroundColor(this, Colors.Yellow);

            prog = new ProgressIndicator();
            prog.IsVisible = true;
            prog.IsIndeterminate = true;
            prog.Text = "Click me...";

            SystemTray.SetProgressIndicator(this, prog);
        }
    }
}

The following code example shows how to use the ProgressIndicator on the SystemTray from XAML. This code goes inside your PHONE:PHONEAPPLICATIONPAGE element. Note that the IsIndeterminate, IsVisible, Text, and Value attributes can all be data-bound.

<shell:SystemTray.ProgressIndicator>
    <shell:ProgressIndicator IsIndeterminate="True" IsVisible="True" Text="Click me..." />
</shell:SystemTray.ProgressIndicator>

Windows Phone OS

Supported in: 7.1

Windows Phone

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.

Did you find this helpful?
(1500 characters remaining)
© 2013 Microsoft. All rights reserved.