Force a TEdit to accept only numeric input #151
I've seen the tip to make a TEdit accept only numbers but there is an easier way to do it. This is the function I use in my applications:
procedure SetEditNumeric(Handle: THandle); begin SetWindowLong(Handle, GWL_STYLE, GetWindowLong(Handle, GWL_STYLE) or ES_NUMBER); end;
Author: | JM |
---|---|
Contributor: | JM |
Added: | 2009/12/05 |
Last updated: | 2009/12/05 |