I do a lot of work with JSON while interacting with various APIs so I use ParseJSON a lot and have always been curious about how the resulting dictionaries interact with the debugger.
Take a look at this code:
dim d1 as Dictionary = ParseJSON("{""data"":[""test"",true,0,{""stringValue"":""aString""}]}")
dim v() as Variant
dim d as new Dictionary("stringValue":"aString")
v.Append "test"
v.Append true
v.Append 0
v.Append d
dim d2 as new Dictionary("data":v)
The array in d1 previews like this:
So it knows that the first 3 values are primitives, but it won’t show the actual value. Clicking the link is of no use, since it doesn’t show the value there either. If that worked it would be annoying, but at least usable.
So I tried the same with the variant array v and it previews like this:
But as soon as you throw the variant array into a dictionary, then it no longer shows you you the values and is back to:
Is this just because of a limitation of the dictionary mode of the debugger, or is there something else going on here that I’m overlooking?
Another related question that I’ll tack on here… Does anyone else have crashes when you’re trying to debug a fairly deep dictionary that has been parsed from JSON?
Thanks