edit só receber numeros

Delphi

02/06/2003

como faço para um campo edit só receber valores numérico?
Valeu


Fer

Fer

Curtidas 0

Respostas

Gedai

Gedai

02/06/2003

No evento onkeypress digite o seguinte:
if not(Key in [´0´..´9´, #8, 13]) then
begin
Key := 0;
end;

onde:
8 = backspace,
13 = Enter,
0 = Tecla nula(não faz nada).


GOSTEI 0
POSTAR