I have a string getting posted to my MVC action that looks like this:
[{"property":"radius","value":"twentyfive"},{"property":"latlng","value":"40.036218,-75.51381100000003"}]
I need the radius value of twentyfive in this case, but could be anything, and also each latitude and longitude number, so they would be 40.036218 and -75.51381100000003 here.
so something like:
string filter = "[{\"property\":\"radius\",\"value\":\"twentyfive\"},{\"property\":\"latlng\",\"value\":\"40.036218,-75.51381100000003\"}]";
string radius = //whatever i need to do;
double lat = //whatever i need to do;
double lng = //whatever i need to do;
Thanks!
You can create a class like this
and use
JavaScriptSerializer