Delphi控制输入为数字或字母

来源:岁月联盟 编辑:exp 时间:2012-06-02


Delphi 控制输入为数字或字母

if not (Key in ['0'..'9', 'a'..'z', 'A'..'Z', #8, #13]) then
begin
  Key := #0;
  ShowMessage('请输入数字或字母');
end;




摘自 Ciske Liu

图片内容