I am trying to pass a javascript array where the values are from a multiselect box. However I am getting a null back from the ajax get request when it hits the action. I have tried to set a breakpoint and it comes back as null. Here is my action signature
public JsonResult GetMessages(List<string> id, string searchText)
and here is my ajax call:
$.get("Dashboard/GetMessages", $.param({ "id": JSON.stringify(selectedID), "searchText": InputSearch }, true)
, function (result) {
for (var item = 0; item < result.length; item++) {
var newMessageEntry = "<tr><td>" + result[item] + "</td></tr>"
}
})
selectedID
?