Subject | Re: [IBO] TIB_CtrlGrid and tab order/focus |
---|---|
Author | Andreas Pohl |
Post date | 2002-06-27T07:20:40Z |
This is working for me:
Shift: TShiftState);
begin
inherited;
if (Key= VK_RETURN) AND (Shift<>[ssCtrl]) then begin
IB_CtrlGrid1.SelectNext(not(Shift=[ssShift]));
abort;
end;
end;
begin
IB_Edit1.SetFocus; // First control in IB_ctrlgrid
IBP_Query4.FieldByName('posnr').AsInteger:=IBP_Query4.RowNum;
IBP_Query4.FieldByName('hauptpos').AsBoolean:=IBP_Query4.rownum=1;
IBP_Query4.FieldByName('lager').AsInteger:=0;
IBP_Query4.CalculateFields;
end;
Mit freundlichem Gruss & Best Regards
Andreas Pohl
ibp consult
> dialog and has a taborder and tabStop=true. I can tab-cycle throughprocedure TPPlanung.IB_CtrlGrid1KeyDown(Sender: TObject; var Key: Word;
> the dialog controls, including the grid, but not through the edit
> boxes (or controls in general) inside the grid.
Shift: TShiftState);
begin
inherited;
if (Key= VK_RETURN) AND (Shift<>[ssCtrl]) then begin
IB_CtrlGrid1.SelectNext(not(Shift=[ssShift]));
abort;
end;
end;
> Anyone known how to accomplish this? Furthermore, I would like toprocedure TPPlanung.IBP_Query4AfterInsert(IB_Dataset: TIB_Dataset);
> start the dialog with the 1st control inside the grid having the
> focus. However, setting the focus to the grid doesn't "forward" the
begin
IB_Edit1.SetFocus; // First control in IB_ctrlgrid
IBP_Query4.FieldByName('posnr').AsInteger:=IBP_Query4.RowNum;
IBP_Query4.FieldByName('hauptpos').AsBoolean:=IBP_Query4.rownum=1;
IBP_Query4.FieldByName('lager').AsInteger:=0;
IBP_Query4.CalculateFields;
end;
Mit freundlichem Gruss & Best Regards
Andreas Pohl
ibp consult