if key=#24 then 
begin 
   ................
  end;好久没用了,不知道怎么写了具体。
多个TEXT框。TABORDER已经设置好了。如何上下移动同时录入,这句不会写了。

解决方案 »

  1.   

    procedure TForm1.Edit2KeyDown(Sender: TObject; var Key: Word;
      Shift: TShiftState);
    begin
      if Key=VK_UP then
        Edit1.SetFocus
      else if Key=VK_DOWN then
        Edit3.SetFocus;
    end;
      

  2.   

    if   Key  = vk_Down  then
            form1.SelectNext(activecontrol,true,true)
        else
            if   Key = vk_up   then
                form1.SelectNext(activecontrol,false,true) 这么写是不对的吗?
      

  3.   

    有很多个TEXT框。 Edit3  Edit1 是代表什么意思呀