i just want to convert string to datetime and then store the date in asp.net calander control's Visible date property. Following is my code
$.ajax({
type: "POST",
url: "dataCheck.aspx/calanderdates",
data: '{item:"' + item + '"}',
contentType: "application/json; charset=utf-8",
dataType: "json",
success: function (response) {
var sdate = Date(response.d)
cal.attr("VisibleDate", sdate);
},
error: function () {
alert(msg.status);
}
});
});
});
But code is not working