John and Jim,
MST changed default designing/compilation model in ASP.NET 2.0. By default
AutoEventWireup is set to true, which instructs compiler to automatically
attach event handlers from the code behind/beside file using naming
convention (for the page events) i.e.
protected void Page_Load(...)
{
}
is automatically attached behind the scenes:
this.Load += new EventHandler(this.Page_Load)
or controls declarative properties:
<asp:GridView runat="server" id="gv" OnRowDataBound="myeventhandlername"/>
is resolved by compiler as:
gv.RowDataBound += new RowDataBoundEventHandler(this.myeventhandlername);
Hope this helps
--
Milosz
"Jim Anderson" wrote:
They are contained in a #region in your form's code behind .cs file annotated
"Web Form Designer generated code" which by default is minimized in Visual
Studio. Just click the plus sign to the left of "Web Form Designer generated
code" to expand the region and see the code.
--
Jim Anderson, MCSD
Consultant
Columbus, Ohio
"john_c" wrote:
When I add a new aspx page to my project, I don't see Init() or
InitializeComponent() in any of the page's CS files. Where are the
methods stored?
Thanks.