Masked edit control in GUI
#1
Posted 03 February 2005 - 08:35 PM
As it is planned ot have a "light" support of Regex, perhaps it can be "merged" with an edit control to give a masked edit control, an edit control with a mask, with the help of the regex support in AHK.
For example, with a mask like "#0.00", the user have the ability to enter a number, with any number of digits (# is the equivalent of *, but only for numbers, not for letters too like *, witch would be for numbers & letters (in my mind...)), but at least one digit followed by a decimal point and by two digits (0.00)
With a mask like "00/00/0000", the user would be able to enter only a date , in the format "dd/mm/yyyy" or "mm/dd/yyyy", and with this fixed place format, (only one digit from 0 to 9 possible in one place), the user woud not to have to type the slashes. I know this sort of things can be done by the way of a SetTimer comand, like in this - old - post, but I think that if it was an inbuilt option, it would be better....
Of course, the use of the range option ([01-12] for the month number, for example) would be possible.
Am I overdemanding ?
#2
Posted 04 February 2005 - 06:56 AM
A date-picker control is planned. It's probably not hard to implement so probably should have been done earlier.With a mask like "00/00/0000", the user would be able to enter only a date , in the format "dd/mm/yyyy" or "mm/dd/yyyy",
The current idea for RegEx is to start off with support for wildcards (* and ?) only. I know this isn't really RegEx, but it seems like it would be a big benefit.an edit control with a mask, with the help of the regex support in AHK.
I know this sort of things can be done by the way of a SetTimer comand, like in this - old - post, but I think that if it was an inbuilt option, it would be better....
It would be nice to have formats enforced as you describe, though to be honest, it's hard to justify making it a higher priority than something like SysListControl32 (which is a control much like a spreadsheet). And even SysListControl32 is probably a couple months away at this rate.
One thing that might help in the future is the ability to assign a g-label to an Edit control. This would avoid the need for SetTimer and also improve performance. If you think this would help you, I can try to give this a higher priority.
In any case, I've made a copy of your post for use when the time comes for this idea is revisited. Thanks.
#3
Posted 04 February 2005 - 05:28 PM
I know that the date-picker control is planned and I think it can be very usefull. My wish of a maked edit control is not for me a high priority. I think, it can be a good enhancement of the edit control as it can allow the user to enter only the necessary information.
For example, to enter a phone number with a mask like : "00.00.00.00.00" (french national format), the user has no need to enter the dots, so if there are a lot of phone numbers to enter, it can be very faster and error free with a masked edit control than without.
What do you mean by
?the ability to assign a g-label to an Edit control
Does it means that an event would act a G-label each time a letter (or number...) is entered in an edit control ? It can be very usefull....
#4
Posted 04 February 2005 - 11:47 PM
Yes, I think that's how it would be, though it might be better to default it to running the label only when the user tabs away from the field or presses a button to submit the form. There could be another mode to run the label for every keystroke made in the field.What do you mean by
Does it means that an event would act a G-label each time a letter (or number...) is entered in an edit control?the ability to assign a g-label to an Edit control
#5
Guests
Posted 05 February 2005 - 08:44 AM
#6
Posted 05 February 2005 - 09:00 AM




