I have a controller with an action method as follows:
public class InventoryController : Controller
{
public ActionResult ViewStockNext(int firstItem)
To rephrase Jarret Meyer's answer, you need to change the parameter name to 'id' or add a route like this:
routes.MapRoute(
"ViewStockNext", // Route name
"Inventory/ViewStockNext/{firstItem}", // URL with parameters
new { controller = "Inventory", action = "ViewStockNext" } // Parameter defaults
);
The reason is the default route only looks for actions with no parameter or a parameter called 'id'.
Edit: Heh, nevermind Jarret added a route example after posting.