在保存前弹出一个“确定与否”的窗口,如是,则保存,如否则不保存?
protected void Page_Load(object sender, EventArgs e)
{
if (!this.IsPostBack)
{
btnSave.Attributes.Add("onclick", "javascript:confirm("确定保存")");
}
}
Response.Write("<script language='javascript'>if(confirm('提交成功继续'))window.close();</script>");