Why is Page_Load not firing after coming back from another page using ASP.NET - ergo epic embarrassment :)

前端 未结 7 1790
故里飘歌
故里飘歌 2021-02-14 22:15

Let\'s say I have two pages on the same ASP.NET C# WebSite.

  • Page1.aspx does things in the Page_Load event
  • I navigate to Page2.aspx using the menu
7条回答
  •  囚心锁ツ
    2021-02-14 22:59

    Try using Server.Transfer instead of Response.Redirect.

    The client will not see the URL change but this may not matter, depending on your requirements

提交回复
热议问题