c# .net Adsense ADO.NET Linq Viruses/security asp.net MVC JQuery Angular-js Node-js SEO Java C++ SQL API Networking vb.net .Net Css JavaScript Generics c#.Net entity framework HTML Website host Website Construction Guide HTTP tutorial W3C tutorial Web Services JSON Psychology Ionic framework Angular ReactJS Python Computer Android
asp.net MVC

How to use RedirectToAction in asp.net MVC?

| | ASP-NET , MVC

In this Article, I explain how to use RedirectToAction in asp.net mvc. Why we use RedirectToAction?. For using RedirectToAction function we have to redirect your controller from one to another with different type of views.  Here I demonstrate with simple example of using RedirectToAction method with passing parameters(Arguments).

Syntax

return RedirectToAction("actionName", "ControllerName",routevalue);

example

 return RedirectToAction("Index","controller", new { id = value });