10

System.Collections.Specialized contains StringDictionary http://msdn.microsoft.com/en-us/library/system.collections.specialized.stringdictionary.aspx#Y1626

What's difference with Strong Typed Dictionary in Generics?

apaderno
  • 26,733
  • 16
  • 74
  • 87
user310291
  • 35,095
  • 76
  • 252
  • 458

1 Answers1

19

StringDictionary comes from .Net 1, which predates generics.

Therefore, unlike Dictionary<String, String>, it doesn't implement any generic interfaces, so it cannot be used with LINQ (unless you Cast())

Also, StringDictionary normalizes all keys to lowercase.
(To make a case-insensitive Dictionary<String, String>, pass StringComparer.OrdinalIgnoreCase; this is also more compatible with Turkey)

SLaks
  • 837,282
  • 173
  • 1,862
  • 1,933