大家好,我有以下代码:
var v = gridInList.Select(s => s.HeaderCellText == cmbScegliColonnaPopolazione.Text).Cast<myGrid.GridInList>();
myGrid.GridInList
tempClass =(myGrid.GridInList) v;
当我运行程序时,我得到了这个错误:
Unable to cast object of type '<CastIterator>d__b1`1[myGrid.GridInList]' to type 'myGrid.GridInList'.
我怎么解决这个问题?