Hej hej,
I have a list of my own object PossibleField like this.
Then I add some objects to the PossfibleFields with the .Add(....) function
And if I do a count, all the object are in the list.
Then I want tot do a foreach of all the possiblefield's .
But the compiler says the following: value cannot be null, parameter name: key.
The same code worked before. Not only with the foreach, also with FirstOrDefault, Find, .... All the functions that retrieve something of the list.
Does anybody has any idea? I'am willing to try everything :D
Greetz,
Jonathan
I have a list of my own object PossibleField like this.
Code:
private List<PossibleField> PossibleFields {get; set; }
And if I do a count, all the object are in the list.
Then I want tot do a foreach of all the possiblefield's .
Code:
foreach(PossibleField field in PossibleFields)
{
}
The same code worked before. Not only with the foreach, also with FirstOrDefault, Find, .... All the functions that retrieve something of the list.
Does anybody has any idea? I'am willing to try everything :D
Greetz,
Jonathan
Comment