我使用以下脚本显示确认消息框。我想要最高检查确认状态是否可以。我怎么检查这个?
ScriptManager.RegisterStartupScript(this, this.GetType(), "temp", "<script language='Javascript'>confirm('ERROR ALERT : " + status + " You can not create record for the above list! Do you want to proceed ?');</script>", false);
答案 0 :(得分:0)
确认返回布尔值(true or false)
,您可以将其分配给变量,详细了解确认here。
ScriptManager.RegisterStartupScript(this, this.GetType(), "temp", "<script language='Javascript'>result = confirm('ERROR ALERT : " + status + " You can not create record for the above list! Do you want to proceed ?');</script>", false);