Can someone help me make a common dispatcher method to invoke any control method, if that make any sense. Is there a better way to do this below also. I want to turn this method functionality into something common, because I have to use multiple times in various places.
private Dataset _ColorDataset; //This is a global dataset
Dispatcher.BeginInvoke(DispatcherPriority.Normal, new Action(DataSourceRefresh));
private void DataSourceRefreshHack()
{
this.colorTable.DataSource = _ColorDataset.Tables["colorTable"].AsDataView();
}