当前位置:   article > 正文

ObservableCollection<object> 转List<T>_observablecollection转list

observablecollection转list

ObservableCollection<object>  转 List<T>
List<object> list = dgReport.SelectedItems.ToList();
Object ob = (Object)list;
 List<T> composes = (List<T>)ob;

ObservableCollection<object> 互转 List<object>

T tList = new List(tObjectStruct .ToList());  
ObservableCollection tObjectStruct  = new ObservableCollection(tList); 

tList.ForEach(p => tObjectStruct.Add(t));

声明:本文内容由网友自发贡献,不代表【wpsshop博客】立场,版权归原作者所有,本站不承担相应法律责任。如您发现有侵权的内容,请联系我们。转载请注明出处:https://www.wpsshop.cn/w/我家自动化/article/detail/114495
推荐阅读
相关标签
  

闽ICP备14008679号