redirect to new page when i click on Cancel button in C# (webpart)

后端 未结 3 1701
庸人自扰
庸人自扰 2021-01-26 18:34
// Cancel button
            tc = new TableCell();
            btnCancel = new Button();
            btnCancel.Text = \"Cancel\";
            btnCancel.Click += new Even         


        
3条回答
  •  有刺的猬
    2021-01-26 19:09

    To do exactly what you want, on the server, would be Response.Redirect. There is no need to postback though. There are a few client side solutions. Use a LinkButton, w/ onclick html attribute set to false. My recommendation is something like this though:

     
    

提交回复
热议问题