【发布时间】:2011-10-06 19:52:42
【问题描述】:
我使用扩展的 WPF 工具包 BusyIndicator
我的 Xaml
<extToolkit:BusyIndicator Name="wait" IsBusy="False" Cursor="Wait" Grid.ColumnSpan="3" Margin="10,10,10,10"/>
我的代码:
private void esp_Click(object sender, RoutedEventArgs e)
{
wait.IsBusy = true;
// My work here make some time to finish
wait.IsBusy = false;
}
但它永远不会显示,我尝试让 MessageBox 在函数末尾显示 BusyIndicator 在 MessageBox 之后显示,
我试过了
wait.Dispatcher.BeginInvoke(System.Windows.Threading.DispatcherPriority.Send,
(Action)delegate
{
wait.IsBusy = true;
});
但是我什么都没有!!! 我无法解决的问题在哪里?
我发现了一个类似的问题,但我没有遇到同样的问题,但在功能完成后指示器显示。
【问题讨论】:
标签: c# wpf xaml busyindicator