Javascript, MVC Controller caling and return parameters
问题 I am able to call a controller method from Javascript. The controller method has Actionresult as return type. Can someone explain, how to return a populated ArrayList from the called controller method, to the calling javascript? How should the javascript handle the returned arraylist? Regards, Anil 回答1: return your arraylist as... return Json(arraylist); then iterate through like an object array function(result) { $.each(result, function(i, item){ alert(item.title + " : " + item.key); }); 回答2