I want to call a JavaScript function in c# code in asp.net mvc3 view, but don't know how to do this. My code is following
Javascript Function
function JK(){
alert("Javascript Function Called From foreach");
}
C# Foreach
foreach(var item in collection){ //I want to call JavaScript function here on every iterate.
}
See Question&Answers more detail:os