Mohammad_Saheb

ActionName

Apr 6th, 2012
148
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C# 0.50 KB | None | 0 0
  1. public class HomeController : Controller
  2.     {
  3.         [HttpGet]
  4.         public ActionResult Index()
  5.         {
  6.             ViewBag.Message = "Welcome to ASP.NET MVC!";
  7.  
  8.             return View();
  9.         }
  10.        
  11.         [HttpPost]
  12.         public ActionResult Index()
  13.         {
  14.             ViewBag.Message = "Welcome to ASP.NET MVC!";
  15.  
  16.             return View();
  17.         }
  18.     }
  19.  
  20. //Type 'xxx.Controllers.HomeController' already defines a member called 'Index' with the same parameter types
Advertisement
Add Comment
Please, Sign In to add comment