Quantcast
Channel: ASPSnippets RSS Feed
Viewing all articles
Browse latest Browse all 4776

ASP.Net MVC: Return NULL from ActionResult

$
0
0
Here Mudassar Ahmed Khan has explained with an example, how to return NULL (Nothing) from ActionResult (Action Method) in ASP.Net MVC Razor. There are two ways to return NULL from an ActionResult (Action Method): 1. Using EmptyResult class. In order to learn more about EmptyResult class, please refer my article ASP.Net MVC EmptyResult Example: Return NULL (Nothing) from Controller to View. 2. Simply return NULL value. In such case, ASP.Net automatically returns EmptyResult class object internally.

Viewing all articles
Browse latest Browse all 4776

Trending Articles