1
我讀過,我們無法從其他工作線程訪問Silverlight應用程序的主UI線程中的任何內容。如何從其他線程訪問主UI線程中的System.Windows.Threading.Dispatcher?
那麼,爲什麼有可能訪問一個類System.Windows.Threading.Dispatcher的對象,該對象與其他工作線程中的主UI線程關聯時,我們想要委派一些工作在用戶界面上完成?
public partial class DispatcherExample : UserControl
{
public void AnyFunctionExecutingInSomeOtherThread()
{
this.Dispatcher.BeginInvoke(SomeDelegate);
}
}