469,938 Members | 2,471 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,938 developers. It's quick & easy.

Page_Load not firing

I have web user controls (ascx files) in multiple support assemblies; I'm
building on a Commerce Server SDK sample. My problem is that the code
behind Page_Load event is never getting called for the web user controls is
one assembly though the Page_Init is fired. The Page_Load has the
"Handles MyBase.Load" but still, when I step through the debugger the init
sub works and the load is fired executed. In all the other support
assemblies in the same solution the web user controls do work correctly.
So why would the load not fire?
#Region " Web Form Designer Generated Code "
'This call is required by the Web Form Designer.
<System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent()
End Sub

Private Sub Page_Init(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Init
'CODEGEN: This method call is required by the Web Form Designer
'Do not modify it using the code editor.
InitializeComponent()
....
End Sub
#End Region

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
...
End Sub
Thanks

Brad
Nov 17 '05 #1
5 7703
Hi Brad,

Is the method Page_Load not fired or it can't stop at a breakpoint in it?
It is weird that this problem only occur with one web form. Is the web form
different with others, for example, including any doubtful code or some
components which is never used in other web form?

Luke

"Microsoft Security Announcement: Have you installed the patch for
Microsoft Security Bulletin MS03-026?? If not Microsoft strongly advises
you to review the information at the following link regarding Microsoft
Security Bulletin MS03-026
http://www.microsoft.com/security/se...s/ms03-026.asp and/or to
visit Windows Update at http://windowsupdate.microsoft.com to install the
patch. Running the SCAN program from the Windows Update site will help to
insure you are current with all security patches, not just MS03-026."

Nov 17 '05 #2
Do you have the event wired up?

this.Load += new System.EventHandler(this.Page_Load);
"Brad" <no****@co.lane .or.us> wrote in message
news:Om*************@TK2MSFTNGP12.phx.gbl...
I have web user controls (ascx files) in multiple support assemblies; I'm
building on a Commerce Server SDK sample. My problem is that the code
behind Page_Load event is never getting called for the web user controls is one assembly though the Page_Init is fired. The Page_Load has the
"Handles MyBase.Load" but still, when I step through the debugger the init
sub works and the load is fired executed. In all the other support
assemblies in the same solution the web user controls do work correctly.
So why would the load not fire?
#Region " Web Form Designer Generated Code "
'This call is required by the Web Form Designer.
<System.Diagnostics.DebuggerStepThrough()> Private Sub InitializeComponent() End Sub

Private Sub Page_Init(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Init
'CODEGEN: This method call is required by the Web Form Designer
'Do not modify it using the code editor.
InitializeComponent()
....
End Sub
#End Region

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
...
End Sub
Thanks

Brad

Nov 17 '05 #3
I do, I'm using VB so using "Handles MyBase.Load.".....which again works
fine in the other assemblies.

"Dino Chiesa [MSFT]" <di****@microsoft.com> wrote in message
news:el***************@tk2msftngp13.phx.gbl...
Do you have the event wired up?

this.Load += new System.EventHandler(this.Page_Load);
"Brad" <no****@co.lane .or.us> wrote in message
news:Om*************@TK2MSFTNGP12.phx.gbl...
I have web user controls (ascx files) in multiple support assemblies; I'm building on a Commerce Server SDK sample. My problem is that the code
behind Page_Load event is never getting called for the web user controls

is
one assembly though the Page_Init is fired. The Page_Load has the
"Handles MyBase.Load" but still, when I step through the debugger the init sub works and the load is fired executed. In all the other support
assemblies in the same solution the web user controls do work correctly.
So why would the load not fire?
#Region " Web Form Designer Generated Code "
'This call is required by the Web Form Designer.
<System.Diagnostics.DebuggerStepThrough()> Private Sub

InitializeComponent()
End Sub

Private Sub Page_Init(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Init
'CODEGEN: This method call is required by the Web Form Designer
'Do not modify it using the code editor.
InitializeComponent()
....
End Sub
#End Region

Private Sub Page_Load(ByVal sender As System.Object, ByVal e As
System.EventArgs) Handles MyBase.Load
...
End Sub
Thanks

Brad


Nov 17 '05 #4
> Is the method Page_Load not fired or it can't stop at a breakpoint in it?
Well, both...since it's not executing I can't step into it or hit a
breakpoint on it. I know it's not executing as I'm not getting back any
result from the load event processing...not even very simple results. It's
not occuring in a web form.....it's in web user controls....and all the web
user controls in one particular assembly (the forms are in the main web
assembly and the controls in questions are in a support assembly).

""台灣微軟技術處支援部"" <lu******@online.microsoft.com> wrote in message
news:Nc**************@cpmsftngxa06.phx.gbl...
Hi Brad,

Is the method Page_Load not fired or it can't stop at a breakpoint in it?
It is weird that this problem only occur with one web form. Is the web form different with others, for example, including any doubtful code or some
components which is never used in other web form?

Luke

"Microsoft Security Announcement: Have you installed the patch for
Microsoft Security Bulletin MS03-026?? If not Microsoft strongly advises
you to review the information at the following link regarding Microsoft
Security Bulletin MS03-026
http://www.microsoft.com/security/se...s/ms03-026.asp and/or to visit Windows Update at http://windowsupdate.microsoft.com to install the
patch. Running the SCAN program from the Windows Update site will help to
insure you are current with all security patches, not just MS03-026."

Nov 17 '05 #5
Hi Brad

Have you found the root cause for the problem?

Thanks,

Luke

(This posting is provided "AS IS", with no warranties, and confers no
rights.)

Nov 17 '05 #6

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

7 posts views Thread by Shane Bishop | last post: by
14 posts views Thread by V. Jenks | last post: by
2 posts views Thread by Dave | last post: by
4 posts views Thread by Seraph | last post: by
1 post views Thread by Ahmet Gunes | last post: by
1 post views Thread by =?Utf-8?B?TWlrZXkgQmFieQ==?= | last post: by
1 post views Thread by Randy | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.