开发者

Asp.Net Page Load

开发者 https://www.devze.com 2023-01-17 22:33 出处:网络
i have a weird problem ! i have ASP.NET website and i have a page with page_load which never get executedno matter what i do ,i deleted the page_load and doubled clicked the aspx page it generated pag

i have a weird problem ! i have ASP.NET website and i have a page with page_load which never get executedno matter what i do ,i deleted the page_load and doubled clicked the aspx page it generated page_load again i inserted my code inside and made breakpoint but it never get hit !

All other Methods gets hit normal like button click and gridview events etc.

ASP.NET 4

it only happens with th开发者_JS百科is page only.

any one ever faced this weird problem ?


Only logical cause for you problem is that AutoEventWireup directive is set to false. Either on the page or in the web.config.

Alternatively you could use this code:

protected override void OnLoad(EventArgs e)
{
  base.OnLoad(e);

  //Do your stuff
}
0

精彩评论

暂无评论...
验证码 换一张
取 消