void serviceClient_GetApplicationConfigCompleted(object sender, GetApplicationConfigCompletedEventArgs e) { m_ConfigList = e.Result; Action callback = e.UserState as Action; if (callback != null) { callback(); } }
void serviceClient_GetApplicationConfigCompleted(object sender, GetApplicationConfigCompletedEventArgs e) { if (e.Error != null) { Window.MessageBox.Show(e.Error.Message, MessageBoxType.Error); return; } if (e.Result != null && e.Result.Count > 0) { ObservableCollection <ConfigModel> list = new ObservableCollection <ConfigModel>(); foreach (var item in e.Result) { list.Add(item.ConvertTo <ConfigModel>()); } DataGridConfigList.ItemsSource = list; } }