RT

解决方案 »

  1.   

    在 onkeypress事件中写
    if key = '.' then
            key := #0;
      

  2.   

    在KeyPress事件中:
    if Key:='.' then
      Key:=#0;
      

  3.   

    procedure TForm1.spinEdit1KeyPress(Sender: TObject; var Key: Char);
    var
      i: integer; //得到小数点的个数
    begin
      i := Length(StringReplace(spinEdit1.Text,'.','&&',[rfReplaceALL]))-Length(spinEdit1.Text);
      if (i > 0) and (key = '.') then
        Key := #0;
    end;
      

  4.   

    SkinEngine的SpinEdit有这种功能,就是ValueType,选择Integer型就可以了。
      

  5.   

    SkinEngine是什么哦?哪里能找到?
      

  6.   

    http://www.playicq.com/dispdocnew.php?id=20437