Subject | IB_Query OnValidateField event |
---|---|
Author | Roberto Freitas |
Post date | 2005-10-13T10:09:07Z |
I have this code in a IB_Query OnValidateField event:
if AField.FieldName = 'CCT_TIPO' then
begin
SAUX := Arow.ByName('CCT_TIPO').AsString;
if ((not (SAUX = 'S')) and (not (SAUX = 'A'))) then
begin
MessageDlg('Invalid Type', mtError, [mbOK], 0);
Abort;
end;
end;
The user types field's value on a TIB_Grid and, if it's invalid,
program shows the error message.
How can I get the old value automatically to be show on the grid
afterwards?
if AField.FieldName = 'CCT_TIPO' then
begin
SAUX := Arow.ByName('CCT_TIPO').AsString;
if ((not (SAUX = 'S')) and (not (SAUX = 'A'))) then
begin
MessageDlg('Invalid Type', mtError, [mbOK], 0);
Abort;
end;
end;
The user types field's value on a TIB_Grid and, if it's invalid,
program shows the error message.
How can I get the old value automatically to be show on the grid
afterwards?