IPhone interaction with ASP.NET WebService

iphoneweb services

I have to develop an application, which will request to a web service developed in ASP.NET.

I don't know, what is the code of creating a request to asp.net web service,

How asp.net web service will respond to iPhone Application?

How iPhone will parse that response to proper way?

I have already read this question


How to Fetch Data From a WebService in iPhone?


But given link only gives the .pdf file.

My need is sample code – that can explain me how to make connection & retrieve data from asp.net web service.

Best Answer

You can actually make a web service and make it real easy to integrate into your iphone up. I would suggest if you are using .net to create a WCF service with webHttp bidding and implement get and post methods, you can get responses back in json and xml (theres a set of classes to parse Json on the iphone that will make parsing the response a breeze, they are avaialble in the web), with little setup you will be able to perform gets and post from the iphone using NSURLRequest. Heres an article that talks about making a restful wcf service http://www.developer.com/net/article.php/10916_3695436_2. Its also very easy to add authentication and security to your services with WCF.

Related Topic