I have a dictionary object in Visual Basic which I want to access with string keys. The problem is, Visual Basic is storing references to strings, rather than the strings themselves. So when I index the dictionary with a key, it always fails because the object references are not equal. What is the point of a dictionary I cannot index? How do I solve this?
Edit:
To be more clear, I want to be able to use this more like a Python dictionary, where string keys are immutable types and therefore the contents rather than the object references are compared.
Strings in .Net ARE immutable. And Dictionary DOES work as you want it to work: