Código
procedure TForm.Edit1KeyPress(Sender: TObject; var Key: Char);
var
s:string;
begin
s := char(key);
if key = Char(ORD(8)) then
exit
else
if not (s[1] in ['0'..'9']) then
key := char(nil);
end;
Planeta Delphi - www.planetadelphi.com.br - Todos os direitos reservados | Copyright 2001-2009