This project has moved. For the latest updates, please go here.
1
Vote

Serialize/Deserialize SortedList with date

description

Hi
 
I've just tried the following small piece of code:
 
Imports AjaxPro
Module Module1
Sub Main()
Dim s As New SortedList
s.Add(Now, "123456")
Dim os As String = JavaScriptSerializer.Serialize(s)
Dim o As Object = JavaScriptDeserializer.DeserializeFromJson(os, GetType(SortedList))
End Sub
End Module
 
however it throws an exception 'Specified method not supported' in the Deserialize line....
 
am I doing something wrong, or are dates not supported in SortedLists....seems to work with a hashtable
 
TIA
 
Søren

comments