在文本框中不要键入numbes如何使用csharp进行验证 [英] In textbox not to type numbes how to validate using csharp

查看:53
本文介绍了在文本框中不要键入numbes如何使用csharp进行验证的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个文本框如下;

教师代码文本框。



当我运行并输入教师代码中的数字时,那个时间显示弹出消息,请仅在教师代码中键入字符。



我怎样才能使用csharp验证。



请帮帮我。



谢谢和问候,



Narasiman P

i have one textbox as follows;
Faculty Code textbox.

in that when i run and type the number in Faculty Code, that time shows the pop up message,please type charcters only in Faculty Code.

for that how can i validate using csharp.

Please help me.

Thanks & Regards,

Narasiman P

推荐答案

你可以简单地使用正则表达式验证和正则表达式: ^ [a-zA-Z] +
You can simply use regex validation with the regex beeing: ^[a-zA-Z]+





查看此链接了解更多信息:

http://msdn.microsoft.com/en-us/library/ms996428.aspx [ ^ ]



祝你好运!


Check this link for more info:
http://msdn.microsoft.com/en-us/library/ms996428.aspx[^]

Good luck!


嗨朋友.....



有一些有用的链接d无限期地帮助你....



http://stackoverflow.com/questions/13253198/validating-a-textbox-to-allow-only-numeric-values [ ^ ]



http://stackoverflow.com/questions/2108616/validation-textboxes-允许小数 [ ^ ]



http:// stackoverflow .com / questions / 13639526 / textbox-validation-2 [ ^ ]



http://stackoverflow.com/questions/13253198/validating-a-textbox-to-allow-only-numeric-values [ ^ ]



乐意提供帮助
hi friend.....

there are some useful links that definitely help you....

http://stackoverflow.com/questions/13253198/validating-a-textbox-to-allow-only-numeric-values[^]

http://stackoverflow.com/questions/2108616/validation-textboxes-allowing-only-decimals[^]

http://stackoverflow.com/questions/13639526/textbox-validation-2[^]

http://stackoverflow.com/questions/13253198/validating-a-textbox-to-allow-only-numeric-values[^]

happy to help


这篇关于在文本框中不要键入numbes如何使用csharp进行验证的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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