How do you get the proper mapping name from a binding source bound to a List<T>, or an anonymous type, to use on a DataGridTableStyle?
问题 I'm trying to create a DataGridTableStyle object so that I can control the column widths of a DataGrid. I've created a BindingSource object bound to a List. Actually it's bound to an anonymous type list created though Linq in the following manner (variable names changed for clarity of what I'm doing): List<myType> myList = new List<myType>(someCapacity); . ...populate the list with query from database... . var query = from i in myList select new { i.FieldA, i.FieldB, i.FieldC };