(一)后台写JavaScript方式

 Response.Write("<script>widow.alert(\" " + this.Test1.text + "\")</script>" );

(二)Button的OnClientClick 属性方式

注:点取消则不执行服务器端的OnClick事件

例:<asp: button OnClientClick="return confirm('确认要删除吗?' );" />

相关文章:

  • 2022-12-23
  • 2022-12-23
  • 2021-12-15
  • 2021-07-13
  • 2022-12-23
  • 2022-12-23
  • 2021-10-29
猜你喜欢
  • 2022-02-19
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案