单击带有空文本框的按钮并防止出错 [英] click on the button with empty textbox and preventing from the error
本文介绍了单击带有空文本框的按钮并防止出错的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
我将值asp.net页面插入数据库。
如果我不使用验证而没有输入值我直接点击插入按钮,这样就会抛出错误。
如何防止此错误。
我将不得不使用
解决方案
在数据库中允许空值,或者(更好地)验证输入。
i am inserting values asp.net page to database.
if i do not use validation and without entering values i direct click on the insert button so it throws the error .
how do i can prevent from this error .
what i will have to use
解决方案
Either allow null values in your DB, or (better) validate your inputs.
这篇关于单击带有空文本框的按钮并防止出错的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文