You can pass the id as part of the routeValues parameter of the RedirectToAction() method.
return RedirectToAction("Action", new { id = 99 });
This will cause a redirect to Site/Controller/Action/99. No need for temp or any kind of view data.
More Related Contents:
- Get controller and action name from within controller?
- How to call another controller Action From a controller in Mvc
- Why does the property I want to mock need to be virtual?
- MVC – Passing Data with RedirectToAction()
- How to find just Current time and just day in mvc [closed]
- MVC5 Razor html.dropdownlistfor set selected when value is in array
- Why is JsonRequestBehavior needed?
- Questions about using Ninject
- @Html.DropDownListFor how to set default value [duplicate]
- How can I get the client’s IP address in ASP.NET MVC?
- Routing: The current request for action […] is ambiguous between the following action methods
- How to get an ASP.NET MVC Ajax response to redirect to new page instead of inserting view into UpdateTargetId?
- DisplayNameFor() From List in Model
- ASP .NET MVC Disable Client Side Validation at Per-Field Level
- How to do a Bulk Insert — Linq to Entities
- How to redirect from OnActionExecuting in Base Controller?
- Visual Studio – Resx File default ‘internal’ to ‘public’
- I’m getting the “missing a using directive or assembly reference” and no clue what’s going wrong
- MvcSiteMap generating a Menu without messing the breadcumbs
- Possible to access MVC ViewBag object from Javascript file?
- “this” in function parameter
- Test method is inconclusive: Test wasn’t run. Error?
- Read HttpContent in WebApi controller
- Model Binding to Enums in ASP.NET MVC 3
- Get UserID of logged-in user in Asp.Net MVC 5
- Can I use ASP.NET MVC together with regular ASP.NET Web forms
- Complex object and model binder ASP.NET MVC
- Opposite of [compare(” “)] data annotation in .net?
- MVC MapPageRoute and ActionLink
- What does ModelState.IsValid do?