I have the following code in a partial view
Country Selector</label>
@Html.DropDownListFor(model => model.CountryGroup, Model.CountryCodes, new { id = "CountryGroup", name = "country-codes" })
@Html.ValidationMessageFor(model => model.CountryGroup, "*")
In the controller I have
public ActionResult ProcessRemoteOrder()
{
var a = 1;
return null;
}
I am assuming that when the code runs a break point on var a will be hit. it is not.
Can someone tell me where I can findout what how to get the function in the controller is run?
thnx
If you want to call the controller action when you select an item from the dropdown, you need to listen to the
changeevent of the drop down and use jQuery ajax to make a call to the action methodTo check whether it is running. Set a breakpoint in your code on the line you want to debug and when the code execute that line the breakpoint will be highlighted with yellow color.