DevExpress 控件 EditMask Numeric数字类型掩码
来源:互联网 发布:mysql 防止重复update 编辑:程序博客网 时间:2024/04/28 19:28
关于Numeric的EditMask说明:
- 可以用分号“;”分成两部分,前面是正数,后面是负数。(通过用户输入-来切换)
- 正数和负数小数点前、后的有效位数一定要相同,否则会报异常,所谓有效就是0、#、%等这样的。(位数不含负号-)
- 如果“;”字符和Mask负值省略,编辑器将使用默认的负值的NumberFormat对象决定的模式。所以”#######0.00;-#######0.00”和”#######0.00”将是同样的效果,这时建议直接用后者,不但简洁还可以避免正负两部分时小数点前面位数不一致造成异常。
- 如果不小心把EditMask设置成了有两个分号,那么也没有问题,只是第二个分号不做为分隔使用,而是做为负数的一部分,效果就是你一旦切换成负数时第二个分号连同后面的内容都会显示在输入框中,但一定要注意,第二个分号“;”后面不能写0、#、%等有效的掩码字符,否则仍会报异常。
官方说明摘要:
The ‘;’ character is used to separate the masks for positive and negative values.
The mask can contain two parts delimited by the ‘;’ character. The first part defines the mask for entering positive values, the second part specifies a mask for entering negative values. An end-user can toggle the value’s sign by pressing the ‘-’ key. In this case, depending upon the value’s sign, the value entered is automatically reformatted using the corresponding mask.
If the “;” character and mask for negative values are omitted, the editor will use the default pattern for negative values determined by the NumberFormat object.(如果“;”字符和Mask负值省略,编辑器将使用默认的负值的NumberFormat对象决定的模式。)
If the “;” character is followed by an empty string, the editor will not allow end-users to enter negative values.
示例代码
- DevExpress 控件 EditMask Numeric数字类型掩码
- Learning Python Part I之数字类型(Numeric Types)
- 小数类型的数字,数值类型转换[DECIMAL,NUMERIC,FLOAT,INT]
- numeric 类型 的计算
- DevExpress控件
- ABAP中如何检查字母数字类型(alpha numeric)的变量
- bitmask type 位掩码类型
- DevExpress控件汉化
- DevExpress控件之gridControl
- DevExpress控件的使用
- TestComplete测试DevExpress控件
- DevExpress控件汉化详解
- DevExpress控件使用
- DevExpress控件汉化详解
- DevExpress控件使用
- DevExpress控件之皮肤
- progressBarControl控件(Devexpress)
- DevExpress控件之XtraTreeList
- Android基于google-play-services-vision:8.1.0实现动态人脸检测
- 有放回采样和无放回采样
- PeekMessage
- Java中的注解是如何工作的?
- Springmvc常用注解
- DevExpress 控件 EditMask Numeric数字类型掩码
- 4 聚簇因子--优化主题系列
- java基础
- 第五章---引入复制后的数据库架构
- log4j的日志文件保存与spring集成
- maven项目 子模块的myabtis配置文件读取失败
- mac eclipse+pydev的reportlab工具包导入
- 返回上一页
- C语言项目2:图书管理系统