Hi everybody,
I would like to have a text field with some format that would accept only unsigned ints.
Does somebody know how to do this??
I feel is much better than using a onDataChange validation.
Thanks for the help
Cheers
#;INVALID
goldcougar wrote:You might want to try using a column converter instead. You can just change the sign so that its always positive.
Or if you must have it as a format, maybe something like this as the format:
- Code: Select all
#;INVALID
The ; should separate the format so left side is positive values and right side is negative, so you just display something in there so the user knows its bad input. I haven't tried it, but that is a valid java DecimalFormat.
Another option might be to combine the format with a column converter. So if you assign the format of "#;#" then java should leave off the minus sign "-" on the negative value, so it will always look positive in the field. Then use the column converter to actually make it always positive.
Users browsing this forum: No registered users and 5 guests