when i create an aspx page, the header includes something like this:-
<%@ Page Language='C#' MasterPageFile='~/Views/Shared/Site.Master' AutoEventWireup='true' CodeBehind='Create.aspx.cs' Inherits='My.Mvc.Views.Blah' %>
With ASP.NET MVC apps, do we:
- need to include this AutoEventWireUp attribute?
- What happens if we set this to false?
- what does this attribute really do? is it valid for ASP.NET MVC?
thanks heaps folks!
Sorry – the default is true in ASP.NET, so you should explicitly set AutoEventWireup to false in the @ Page directive, or remove it and set it to false in pages section of web.config for MVC.