0

I have developed one online bus seat booking project, here I am using the API for each operation.

One operation had to write the information in .xml file now which they have changed to .json. Already I have got the value from .xml, but I didn't know how to get the value from .json.

1 Answer 1

1

It depends upon type of method you are using. As far as they are GET you can get value from Request.QueryString["Key"] and if the method type is of POST then you can get those from Request.Form["key"].
To return the result in Json format you can either use .Net 3.0 System.Web.script.Serialization namespace which contains Class for converting object to json data JavaScriptSerializer or you can use some third party dll such as JSON.NET One that fall in my favorite list while dealing with jSon data.

Sign up to request clarification or add additional context in comments.

Comments

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.