vb.net - How do I convert this JSON to a object (model)? -


my json looks this...

[     {"success":{"id1":200}},     {"failed":{"id6":true}},     {"success":{"id8":"test"}} ] 

now need figure out how model.

i presume model should this:

public class resultmodel      public enum resultstatus         success         failed     end enum       public class idresult         public property id string         public property data object     end class       public property status resultstatus     public property ids list(of idresult) end class 

but can't figure out how json list of resultmodel?

i know have this...

dim l list(of resultmodel) = directcast(newtonsoft.json.jsonconvert.deserializeobject(of list(of resultmodel))(myjsonstring), list(of resultmodel)) 

but can't figure 1 out.

any appreciated! thanks.


Comments

Popular posts from this blog

Command prompt result in label. Python 2.7 -

javascript - How do I use URL parameters to change link href on page? -

amazon web services - AWS Route53 Trying To Get Site To Resolve To www -