In vb.net there's always three ways to implement a base method. There are
some minor diferences between then (not functionality though). I'd pick the
one the most consistant with how you do it within the rest of your system.
1 - (the way I guess you probably want it)
Protected Sub Page_PreRender(ByVal s As Object, ByVal e As EventArgs)
Handles Me.PreRender
'code here
End Sub
2 -
Protected Overrides Sub onPreRender(ByVal e As System.EventArgs)
'code here
MyBase.OnPreRender(e)
End Sub
3 -
'put this in Init or somwhere
AddHandler Me.PreRender, AddressOf Page_PreRender2
Protected Sub Page_PreRender2(ByVal sender As Object, ByVal e As
System.EventArgs)
'code here
End Sub
Karl
--
MY ASP.Net tutorials
http://www.openmymind.net/ http://openmymind.net/redirector.aspx?documentId=51 - Learn about AJAX!
<wi**************@yahoo.com.au> wrote in message
news:11**********************@g43g2000cwa.googlegr oups.com...
Hi,
Quick question. What's the best way to create the handler for
Page_Prerender in ASP.Net 2.0. I used to just use the dropdowns to
select (Page Events) on the left and choose PreRender in the right hand
dropdown. Now however these are not listed.
Any recommendations?
Stew