This article is a mirror article of machine translation, please click here to jump to the original article.

View: 14899|Reply: 0

[ASP.NET] MVC's ActionResult

[Copy link]
Posted on 9/13/2016 10:52:13 AM | | |

All Controllers inherit from System.Web.Mvc.Controller
Currently ASP.NET MVC3 provides a variety of ActionResult implementations by default, in the System.Web.Mvc namespace.

ActionResult is an abstract class, and all the next Result is inherited from it, so if the return value of an Action is ActionResult, it can return any of the following types of values, but if the return value is any of the following Results, it can only return the specified type of data.

ContentResult
EmptyResult
FileResult
HttpStatusCodeResult
HttpNotFoundResult
HttpUnauthorizedResult
Javascrip{filter}tResult
JsonResult
RedirectResult
RedirectToRouteResult
ViewResultBase
PartialViewResult
ViewResult






Previous:When not running inside a standalone exe, the exePath must be specified
Next:IoC efficient Autofac
Disclaimer:
All software, programming materials or articles published by Code Farmer Network are only for learning and research purposes; The above content shall not be used for commercial or illegal purposes, otherwise, users shall bear all consequences. The information on this site comes from the Internet, and copyright disputes have nothing to do with this site. You must completely delete the above content from your computer within 24 hours of downloading. If you like the program, please support genuine software, purchase registration, and get better genuine services. If there is any infringement, please contact us by email.

Mail To:help@itsvse.com