Iam trying to get the xml data through jquery ajax but it getting error please get me out of here where i it is going to wrong
[WebMethod]
public static XElement GetDetails ()
{
APSRKEntities entity = new APSRKEntities();
XElement xml = new XElement("details",
(from A in entity.Stud_Admission
join B in entity.Stud_Promotion on A.StudID equals B.StudId
join C in entity.Stud_EducHistory on B.StudId equals C.StudID
select new { A.FullName, A.AdmissionNo, A.AdmittedInClass, C.PrevSchoolName, B.Batch, B.Class, B.Section, A.StudID }).Where(x => x.Batch == 2013 && x.Class == 3 && x.Section == 1)
);
return xml;
}
$('.btn').click(function () {
$.ajax({
type: "post",
url: "Default.aspx/GetDetails",
...
Go to the complete details ...