I am calling Ajax with multiple array but not getting function call on click of ctl00_MainContent_btnsaveqfdmatrix i am passing array custreq ,testpara ,category,property1 value in ajax call
$('#ctl00_MainContent_btnsaveqfdmatrix').click(function(e) {
e.preventDefault();
var custreq = [];
var testpara = [];
var category = [];
var property1 = [];
$("#Qfd td").each(function() {
if ($(this).hasClass("highlight1")) {
alert("check1");
cols = $(this).closest("tr").children("td").index($(this));
custreq[i++] = $(this).closest("tr").find("td").eq(0).html(); //colv
if ($(this).closest("tr").find("td").eq(1).hasClass("A")) {
custreq[i++] = $(this).closest("tr").find("td").eq(1).html(); //colv
} else {
cols = 1 + cols
}
testpara[i++] = $("#Qfd tr").eq(1).find("td").eq(cols).html(); //rowv
if (cols <= 6 && cols >= 1) {
category[i++] = 'Alloying';
}
if ($(this).hasClass("highlight1")) {
property1[i++] = "Red"
}
$.ajax({
type: "POST",
url: "Entry.aspx/mcall",
data: {
'custreq': custreq,
'testpara': testpara,
'category': category,
'property1': property1,
'npdno': $("#ctl00_MainContent_lblnpdno").text()
},
contentType: "application/json; charset=utf-8",
dataType: "json",
success: function(data) {
alert("yes");
},
error: function(response) {
alert(response);
}
});
});
in vb .net side calling webmethod mcall but given function is not able to call
<ScriptMethod(),
WebMethod()>
Public Shared Function mcall(ByVal custreq As List(Of String), ByVal testpara As List(Of String), ByVal category As List(Of String), ByVal property1 As List(Of String), ByVal npdno As String) As String
Return "Hello "
End Function
Any idea where is error will be appreciated.