实际开发中,若想让 TEdit 只能接收 数字 输入,可通过简单调用一 API 即可“标准实现”之:
    SetWindowLong(
                             edt1.Handle, //edt1: TEdit;
                             GWL_STYLE,
                             GetWindowLong(edt1.Handle, GWL_STYLE) or ES_NUMBER
                            );

    效果图: