0

当试图访问一个字段的值时,它不允许我获取它,我是在 DataSet 的 OnFiltered 中进行的。

procedure TFrm_Transactions.qry_personal_trxsFilterRecord(DataSet: TDataSet; var Accept: Boolean);
var
  vprs, vtrxs: string;
begin
  if qry_personal_trxs.FindField('TRANSACTIONS') = nil then
    accept := True
  else
  begin
    vprs := DataSet.FieldByName('PERSONAL').AsString;
    vtrxs := DataSet.FieldByName('TRANSACTIONS').AsString;
    accept := (vprs = vPersonal) and (pos(',' + vTransaction + ',', vtrxs) > 0);
  end;
end;
4

0 回答 0