Subject | Problem again with OnDataChange |
---|---|
Author | Kevin Stanton |
Post date | 2002-01-11T21:55:35Z |
Just recently upgraded to D6 and IBO 4.2.Fn.
I have the below Event.
Thing was working fine in D5, IBO 3.6.x.
The CustNo is hooked up to a TIB_LookupCombo on another form.
This event is firing but the Field parameter is coming thru as nil.
Could we get a fix on this asap please?? (or is there something new or
something I'm missing??)
Thanks!
Kevin
procedure TdmDirSales.dsDirHdrDataChange(Sender: TIB_StatementLink;
Statement: TIB_Statement; Field: TIB_Column);
begin
If NOT Assigned(Field) then Exit;
If Field.FieldName = 'CUSTNO' then
begin
qryDirHdr.FieldByName('CUSTSHIPTO1').AsString :=
qryCustLU.FieldByName('ShipTo1').AsString;
qryDirHdr.FieldByName('CUSTSHIPTO2').AsString :=
qryCustLU.FieldByName('ShipTo2').AsString;
qryDirHdr.FieldByName('CUSTSHIPTOCITY').AsString :=
qryCustLU.FieldByName('ShipToCity').AsString;
qryDirHdr.FieldByName('CUSTSHIPTOSTATE').AsString :=
qryCustLU.FieldByName('ShipToState').AsString;
qryDirHdr.FieldByName('CUSTSHIPTOZIP').AsString :=
qryCustLU.FieldByName('ShipToZip').AsString;
qryDirHdr.FieldByName('CUSTSHIPTOCOUNTRY').AsString :=
qryCustLU.FieldByName('ShipToCountry').AsString;
qryDirHdr.FieldByName('CUSTTERMS').AsString :=
qryCustLU.FieldByName('TruckTerms').AsString;
{$IFNDEF LbrEOD}
frmDirectSales2.SetTerms;
{$ENDIF}
end;
If Field.FieldName = 'MILLNO' then
begin
qryDirHdr.FieldByName('MILLTERMS').AsString :=
qryMillLU.FieldByName('TruckTerms').AsString;
{$IFNDEF LbrEOD}
frmDirectSales2.SetTerms;
{$ENDIF}
end;
end;
I have the below Event.
Thing was working fine in D5, IBO 3.6.x.
The CustNo is hooked up to a TIB_LookupCombo on another form.
This event is firing but the Field parameter is coming thru as nil.
Could we get a fix on this asap please?? (or is there something new or
something I'm missing??)
Thanks!
Kevin
procedure TdmDirSales.dsDirHdrDataChange(Sender: TIB_StatementLink;
Statement: TIB_Statement; Field: TIB_Column);
begin
If NOT Assigned(Field) then Exit;
If Field.FieldName = 'CUSTNO' then
begin
qryDirHdr.FieldByName('CUSTSHIPTO1').AsString :=
qryCustLU.FieldByName('ShipTo1').AsString;
qryDirHdr.FieldByName('CUSTSHIPTO2').AsString :=
qryCustLU.FieldByName('ShipTo2').AsString;
qryDirHdr.FieldByName('CUSTSHIPTOCITY').AsString :=
qryCustLU.FieldByName('ShipToCity').AsString;
qryDirHdr.FieldByName('CUSTSHIPTOSTATE').AsString :=
qryCustLU.FieldByName('ShipToState').AsString;
qryDirHdr.FieldByName('CUSTSHIPTOZIP').AsString :=
qryCustLU.FieldByName('ShipToZip').AsString;
qryDirHdr.FieldByName('CUSTSHIPTOCOUNTRY').AsString :=
qryCustLU.FieldByName('ShipToCountry').AsString;
qryDirHdr.FieldByName('CUSTTERMS').AsString :=
qryCustLU.FieldByName('TruckTerms').AsString;
{$IFNDEF LbrEOD}
frmDirectSales2.SetTerms;
{$ENDIF}
end;
If Field.FieldName = 'MILLNO' then
begin
qryDirHdr.FieldByName('MILLTERMS').AsString :=
qryMillLU.FieldByName('TruckTerms').AsString;
{$IFNDEF LbrEOD}
frmDirectSales2.SetTerms;
{$ENDIF}
end;
end;