Hey, If anyone is interested, there's a good article and parser for JSON and use in .Net here. Helped me solve it!
http://msdn.microsoft.com/en-us/library/bb299886.aspx#intro_to_json_topic4 Cheers, On Jan 27, 4:40 pm, "RodgerWilko!" <[email protected]> wrote: > Hi, > > I'm writing a .Net wrapper around the google street view so that users > of .Net can use the technology easier. > > I am currently working on the StreetviewClient. Unfortunatly there is > no HTTP version of this, so I have to create a client in the page, > call the api, and then callback the response to .Net and serialize it. > The basic javascript code is: > > ... > > client = new GStreetviewClient(); > client.getNearestPanorama(new GLatLng(-33.869, 151.219), > HandleNearestPanoramaResult) > > function HandleNearestPanoramaResult(result) > { > ... callback to .Net with result > > } > > ... > > The question I have is, is there a way I can get the result from the > getNearestPanorama callback to be in JSON format, or a standard > format, so that when I serialize it in .Net it's much easier. > > I've tried > result.toSource() > > and the result was: > ({Data:{copyright:"\xA9 2009 Google"}, Location:#1={lat:"-33.869833", > lng:"151.219490", description:"Nicholson St", streetRange:"1", > region:"Woolloomooloo, NSW", country:"Australia", zoomLevels:"3", > panoId:"_sypSOARVD1g1tE3CChsFg", latlng:{Bw:-33.869833, qc:151.21949, > x:151.21949, y:-33.869833}, pov:{yaw:(void 0), pitch:(void 0), zoom: > (void 0)}}, Links:#2=[{yawDeg:"100.49", description:"Nicholson St", > panoId:"XwTvDyHva6DSkjz-K5YM6A", yaw:100.49}, {yawDeg:"280.49", > description:"Nicholson St", panoId:"SGSB9rj5uLug9H_rPqCLWg", yaw: > 280.49}], __shared:(void 0), code:200, location:#1#, copyright:"\xA9 > 2009 Google", links:#2#}) > > So any ideas on how to get it to a nicer standard format? > > Thanks > > RodgerWilko! --~--~---------~--~----~------------~-------~--~----~ You received this message because you are subscribed to the Google Groups "Google Maps API" group. To post to this group, send email to [email protected] To unsubscribe from this group, send email to [email protected] For more options, visit this group at http://groups.google.com/group/Google-Maps-API?hl=en -~----------~----~----~----~------~----~------~--~---
