LookupField have KeyFields with more than one field

Posted by 12068 Sidney on October 16, 2000 at 01:32:50:

: Error using DBLookupComboBox with LookupField when KeyFields and LookupKeyFields have more than one field.
: I have two TTables (Table1 and Table2) in a Form (FormY). In the Table1 are the fields: FieldA, FieldB and LookupFieldF. In the Table2 are the fields: FieldD, FieldE and FieldF. The LookupFieldF in Table1 I created with:
: FieldKind = fkLookup, FieldName = LookupFieldF, KeyFields = FieldA;FieldB(**) LookupDataSet = Table2; LookupKeyFields = FieldD; LookupResultField = FieldF; Name = Table1LookupFieldF.

: (**) Exist in Table, are persistent fields and each field name is separate with a semicolon),

: At design time I drag and drop the three fields of the Table1 in the FormY. When I change Table1.Active for Thru I receive the Message: DBLookupComboBox1 ‘FieldA;FieldB’ not found.
: What is wrong? Please help me.
: Thanks. Sidney ( I use Delphi 4.0).

Related Articles and Replies: