开发者

Parse JSON in iphone application with json-framework

I am new in iphone development.I am using currency converter in my apps. I don't have any idea how 开发者_运维知识库to parse json with this url http://www.google.com/calculator?. I want to send my all detail such as quantiy,select currency,to currency and wants to display the result in label. pls provide any help or any code for me how will i parse this data.


Using SBJson:

NSString *json = @"{lhs: "2 U.S. dollars",rhs: "89.7988506 Indian rupees",error: "",icc: true}"

NSDictionary *jsonDict = [json JSONValue];

NSString *lhs = [jsonDict objectForKey:@"lhs"];
NSString *rhs = [jsonDict objectForKey:@"rhs"];
...


Here is the tutorial to help you out...

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜