I'm trying to replace an old dictionary value with a new collection. I cannot figure out why the key that is being found is not getting deleted. I changed the .CompareMode to TextCompare but still cannot successfully delete the string. Updating the value of the dictionary didn't work either, so I tried to remove then add again. Reference
How can I remove and add back (or update) the key/value pair of the dictionary?
collStr = "testvalue"
c.Add (collStr)
If dict.Exists(Key) Then
dict.Remove Key '<- This should remove but still appearing in 'Watches' dictionary
If Not dict.Exists(Key) Then
dict(Key) = c '<- Trying to replace only dictionary value with new collection
'dict.Add Key, c
End If