范围验证器 [英] rangevalidator

查看:170
本文介绍了范围验证器的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

海友,

这是基兰语,我对rangevalidator有疑问,实际上我使用rangevalidator来进行分类.在这里我给最小值= 1和最大值= 60在这里没问题,但是我也在文本框中使用"AB" ..

显然我使用1到60,文本框中的AB值可以使用..


致以问候,

Kiran kumar reddy.

Hai frnds ,

ths is kiran , i have a doubt in rangevalidator actually i use rangevalidator to taxtbox . here i give Minimum Value = 1 and Maximumvalue = 60 here no problem but i m also use "AB" in textbox ..

clearly i use 1 to 60 and AB values in textbox hw can i use ..


With regards ,

Kiran kumar reddy .

推荐答案

您应在文本框中输入输入内容时使用javascript进行击键事件的数字检查.
You should use javascript for Numeric check in keydown event while entering input in textbox.


也许您使用 RegularExpressionValidator [
maybe if you use RegularExpressionValidator[^] and you can get only digits in range 1 to 60 :

ValidationExpression="\d{1,60}"


这篇关于范围验证器的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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