D
Devon_Nullman
Guest
I am using google to translate, the response is supposedly in JSON format but - My JSON Utility says that it is invalid JSON, others say it's ok but I see no mention of names, just values.
I have tried a supposedly working class for the JSON with both Newtonsoft and the JavaScript Serializer, Both fail. Newtonsoft throws the error that the data is not proper JSON and the JavaScript deserializer throws an exception that no arrays are in the data.
Sample raw output:
[[["\"Hoy es cálido\"","\"Today is warm\"",null,null,3]],null,"en"]
Supposedly Correct Class:
Public Class JsonData
Public Property Data() As Data
End Class
Public Class Data
Public Property Translations() As List(Of Translation)
End Class
Public Class Translation
Public Property TranslatedText() As String
End Class
My question is What would be the proper Class for the raw JSON Data ?
Which is as follows:
[[["\"Hoy es cálido\"","\"Today is warm\"",null,null,3]],null,"en"]
Continue reading...
I have tried a supposedly working class for the JSON with both Newtonsoft and the JavaScript Serializer, Both fail. Newtonsoft throws the error that the data is not proper JSON and the JavaScript deserializer throws an exception that no arrays are in the data.
Sample raw output:
[[["\"Hoy es cálido\"","\"Today is warm\"",null,null,3]],null,"en"]
Supposedly Correct Class:
Public Class JsonData
Public Property Data() As Data
End Class
Public Class Data
Public Property Translations() As List(Of Translation)
End Class
Public Class Translation
Public Property TranslatedText() As String
End Class
My question is What would be the proper Class for the raw JSON Data ?
Which is as follows:
[[["\"Hoy es cálido\"","\"Today is warm\"",null,null,3]],null,"en"]
Continue reading...