如何显示错误信息? [英] How to display an error message?

查看:118
本文介绍了如何显示错误信息?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好!





如何显示此类错误消息,所选项目将被丢弃。你想继续吗?然后在该错误消息中将出现是和否按钮。怎么做?

Hi People!


How am I going to display this kind of error message,"Selected Items will be discarded. Would you like to continue?" Then there will a yes and No button inside of that error message. How to do that?

推荐答案

检查以下链接



确认框(确认框),是否按钮



确认对话框


试试这个,



在你的按钮的onclientclick上添加你的消息,它会提供一个消息框你的文字。



Try this,

Add your message on "onclientclick" in your button,it will provide a message box with your text.

<asp:Button ID="DiscardId" runat="server"  
Text="Discard"  onclick="DiscardId_Click" onclientclick="return confirm('Selected Items will be discarded. Would you like to continue?')" />


这篇关于如何显示错误信息?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆