[英]EXtended WPF toolkit busy indicator
I am using busyindicator tool of Extended WPF tool kit _busy is busyindicator 我正在使用扩展WPF工具包的busyindicator工具_busy是busyindicator
_busy.IsBusy = true;
// Thread.Sleep(20000);
downloadsomedata();
_busy.IsBusy = false;
busy indicator is not showing. 忙碌指示灯未显示。 Though it works when i put whole thing in
BackgroundWorker
but I need to execute other commands only after downloadsomedata()
execution. 虽然当我将所有东西放到
BackgroundWorker
时它可以工作,但是我只需要在执行downloadsomedata()
之后才执行其他命令。 Can anyone help me what is happening here? 谁能帮我这里发生什么事? I tried putting only thread.sleep and not
downloadsomedata();
我试着只放thread.sleep,而不是
downloadsomedata();
but still not showing progress bar? 但仍不显示进度栏?
The BackgroundWorker
class has BackgroundWorker.RunWorkerCompleted Event . BackgroundWorker
类具有BackgroundWorker.RunWorkerCompleted事件 。 So, you can execute other commands in the event handler of this event (see the example for this event on MSDN). 因此,您可以在此事件的事件处理程序中执行其他命令(请参阅MSDN上的此事件的示例)。
One more example: Extended WPF Toolkit–using the BusyIndicator . 再举一个例子: 扩展的WPF工具包-使用BusyIndicator 。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.