Intersoft.Client.UI.Controls Namespace > UXBusyIndicator Class : IsBusy Property |
<CategoryAttribute("Common Properties")> Public Property IsBusy As Boolean
Dim instance As UXBusyIndicator Dim value As Boolean instance.IsBusy = value value = instance.IsBusy
[CategoryAttribute("Common Properties")] public bool IsBusy {get; set;}
[CategoryAttribute("Common Properties")] public: property bool IsBusy { bool get(); void set ( bool value); }
UXBusyIndicator displays a busy visual hint when the control is busy, which is done by setting the IsBusy property to true. You can also easily add a custom content to the busy indicator, such as showing a "Loading..." text, or other content that suitable to your application's context.
The following example shows how to add a text to the busy content and set the busy mode in Button .Click event.
XAML |
Copy Code
|
---|---|
<Intersoft:UXBusyIndicator x:Name="BusyIndicator1" BusyContent="Signing in..."> <Intersoft:DockPanel Width="300" Height="200"> <TextBlock Text="Welcome to My Application" HorizontalAlignment="Center"/> <Intersoft:UXItemsControl Intersoft:DockPanel.IsFillElement="True" Width="300"> <Intersoft:FieldLabel> <Intersoft:UXTextBox Width="150"/> </Intersoft:FieldLabel> <Intersoft:FieldLabel Header="Password:"> <Intersoft:UXPasswordBox Width="150"> </Intersoft:FieldLabel> <Intersoft:FieldLabel Header=""> <Intersoft:UXButton Content="Login" Width="80" IsDefault="True" Click="UXButton_Click"/> </Intersoft:FieldLabel> </Intersoft:UXItemsControl> </Intersoft:DockPanel> </Intersoft:UXBusyIndicator> |
C# |
Copy Code
|
---|---|
private void UXButton_Click(object sender, RoutedEventArgs e) { this.BusyIndicator1.IsBusy = true; } |
The IsBusy property is a dependency property, which means you can bind it to a property in the ViewModel using MVVM design pattern. This allows you to set the busy mode from the user interaction logic in the ViewModel, track the notification and give feedback as a response.
For more information on building Silverlight and WPF application with MVVM design pattern, see MVVM Pattern Overview.
For more information about UXBusyIndicator, see UXBusyIndicator Overview.
Target Platforms: Windows 7, Windows Vista SP1 or later, Windows XP SP3, Windows Server 2008 (Server Core not supported), Windows Server 2008 R2 (Server Core supported with SP1 or later), Windows Server 2003 SP2