I have a menu containing various links to specific pages in my app. One of them has just started exhibiting very strange behaviour. Heres the markup
<li>
<a href="@Url.Action("Index", "Contract",
new { id = Model.ContractId, orgId = Model.OrgId })">
<i class="fa fa-briefcase"></i> Contract Details
</a>
</li>
The controller action method signature:
public async Task<ActionResult> Index(int id, int orgId)
Whenever I click on the link I get this error:
[ArgumentException: Value cannot be null or empty.Parameter name: name] System.Web.Mvc.ActionNameAttribute..ctor(String name) +99
The action exists, the controller exists, the parameters being passed have values, yet I get this error. I've used exactly the same method on various other links in the same page, just to different controllers and they all work fine, it's just this one. I can't see what the problem is. Anyone got any suggestions?