Hi,
Can anyone help explain the following. I am having an issue with a Dictionary where ContainsKey
evaluates to false while both Equals
and GetHashCode
for the objects are successful. Below is the output from the immediate window in Visual Studio:
?LocationToRackingGroup.Keys.ToArray()[23].Equals(location)
true
?LocationToRackingGroup.Keys.ToArray()[23] == (location)
true
?this.LocationToRackingGroup.ContainsKey(location)
false
Am I missing something? Any ideas are much appreciated.
Cheers,
James