using this code in mvc
In view
$(function () {
//Dropdownlist Selectedchange event
$("#ContId").change(function () {
$.get("/Home/GetStateById", { ID: $("ContID").Val() }, function (data) {
$("#St").empty();
$.each(data, function (index, row) {
$("#St").append("
row.Statename + "");
// here we are adding option for States
});
})
});
});
but this is not working plz check this code there is an exception coming at this line .
$.get("/Home/GetStateById", { ID: $("ContID").Val() }, function (data) {
Amit Kumar SinghPosted Dec 24, 2016, 2:30 AM
imran bhattiPosted Dec 24, 2016, 2:05 AM
Midhun TpPosted Dec 24, 2016, 1:50 AM
Amit Kumar SinghPosted Dec 24, 2016, 1:10 AM
Salman BegPosted Dec 23, 2016, 1:16 PM