Advertise here

Advertise here

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

exception when parsing an array in JSON

lucaazorilucaazori Posts: 48
edited May 2011 in iOS SDK Development
hi all, when i try to parse an array returned from my web-service i got this exception :
2011-05-03 23:28:10.021  -JSONValue failed. Error trace is: (
        "Error Domain=org.brautaset.JSON.ErrorDomain Code=11 \"Unexpected end of string\" UserInfo=0x803d8b0 {NSLocalizedDescription=Unexpected end of string}"

here is my code :
-(void)requestFinished:(ASIHTTPRequest *)request{
    	   //parse the response
    		NSArray *array=[[request responseString]JSONValue];
    		listeTypesDesCarburants=[array objectAtIndex:0];
    		listeDesEnseignes=[array objectAtIndex:1];
are both a `NSArray`
Post edited by lucaazori on


Sign In or Register to comment.