On Thu, 2 Dec 2010 15:38:16 +0100, "Tony Johansson"
<(E-Mail Removed)> wrote:
>Hello!
>
>Normally all events can be found in the lightning bold in the property page
>but how can I find these.
>
>protected void Page_Load(object sender, EventArgs e)
> {
> }
>
> protected void Page_Init(object sender, EventArgs e)
> {
> }
>
> protected void Page_PreRender(object sender, EventArgs e)
> {
>
> }
>
ASP.NET webforms do not make use of property pages like ,NET winforms
do. The Page_Load method is automatically stubbed out when the page is
added to the project.
Page_Init and Page_PreRender are the names of specific events which
have pre-existing event handlers at lower levels. These event handlers
are prefixed with On and can be overridden. In the page's .cs files
type override as if you're adding a new method. Hitting the space bar
will bring up Intellisense. Select OnPage_Init and an overridden
handler will be stubbed out. Do the same thing and select
OnPage_PreRender and that overridden handler will be stubbed out as
well.
regards
A.G.
|