asp.net应用程序中的错误检查 [英] Error chek in asp.net Application

查看:83
本文介绍了asp.net应用程序中的错误检查的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我必须在我的网站上进行一些错误检查..这样,只要有人尝试删除任何内容..对话框的出现与带有messagebox.show的桌面应用程序中的对话框相同...是或否.

i have to make some error check in my web site.. in such a way tha whenever some one try to delete anything .. The dilogue box appears same as in desktop applications with messagebox.show ... with yes or no. how to do it in desktop application.

推荐答案

假设您的意思是该对话框出现在客户端浏览器中,(因为您已经知道MessageBox.Show用于桌面应用程序) ,您希望使用Javascript确认框: http://www.w3schools.com/js/js_popup.asp [ ^ ]

这里有一个您正在尝试执行的操作的示例:
Assuming you mean the dialog to appear in your client browser, (since you already know about MessageBox.Show for desktop applications), you are looking to use a Javascript Confirm box: http://www.w3schools.com/js/js_popup.asp[^]

There is an example of exactly what you are trying to do here: Adding Client-Side Confirmation When Deleting (C#)[^]


您可以为这样的提示创建Web表单,我使用jquery,然后在库中添加一个jquery来做到这一点.正确的答案是,您需要显示某种html控件来提示用户,无论它看起来是一个弹出窗口(通常是当今,它是主页的一部分,而javascript用于使其看起来像一个弹出窗口)弹出窗口)
You can create web forms for prompts like this, I use jquery and then a jquery add on library to do exactly that. The correct answer is, you need to show some sort of html control that prompts the user, if it looks like a popup, or not ( typically nowadays, it''s part of the main page and javascript is used to make it look like a popup window )


这篇关于asp.net应用程序中的错误检查的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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