tag:blogger.com,1999:blog-6082652835152798567.post8416698135361520233..comments2024-03-28T21:41:58.974-07:00Comments on Sql server, .net and c# video tutorial: Handling json data returned from asp.net web servicesUnknownnoreply@blogger.comBlogger3125tag:blogger.com,1999:blog-6082652835152798567.post-84976772240937955472016-03-16T00:12:39.237-07:002016-03-16T00:12:39.237-07:00Hello sir,
i have faced a bit of problem while exe...Hello sir,<br />i have faced a bit of problem while executing approach 2,<br />inside the ready function data was not received as json.<br />then i tried to parse it in json.<br />then-after i got output on web page.<br />I am posting the code here.<br /><br /> $(document).ready(function () {<br /> $('#btnGetEmployee').click(function () {<br /> var empId = $("#txtId").val();<br /> $.ajax({<br /> url: 'EmployeeServiceJson.asmx/GetEmployeeById',<br /> data: { employeeId: empId },<br /> method: 'post',<br /> datatype: "json",<br /> success: function (data) {<br /> var obj= JSON.parse(data);<br /> $('#txtName').val(obj.Name);<br /> $('#txtGender').val(obj.Gender);<br /> $('#txtSalary').val(obj.Salary);<br /> },<br /> error: function (err) {<br /><br /> alert(err);<br /> }<br /><br /><br /> });<br /> });<br /> });Anonymoushttps://www.blogger.com/profile/00845701764985328434noreply@blogger.comtag:blogger.com,1999:blog-6082652835152798567.post-59409089868305968302015-09-07T23:40:32.319-07:002015-09-07T23:40:32.319-07:00sir could you please tell me how to populate the j...sir could you please tell me how to populate the json return result to asp.net server controls. if i use html controls the control gets populated with result.<br /><br />Thanks<br />SaravananAnonymoushttps://www.blogger.com/profile/06443194047646231449noreply@blogger.comtag:blogger.com,1999:blog-6082652835152798567.post-36040836074315914992015-06-13T15:06:12.226-07:002015-06-13T15:06:12.226-07:00Hi Sir,
Can u please tell me. How to work with a...Hi Sir, <br /><br />Can u please tell me. How to work with a url where the service will build a query string and handle the json data ?<br /><br />Thanks,<br />LokeshAnonymousnoreply@blogger.com