Subject Re: [IBO] IB_LookupCombo
Author Helen Borrie
At 09:59 PM 7/11/2007, you wrote:
>Hi, I've setup an IB_LookupCombo (Firebird 2 / Delphi 2006) and the
>keylinks and gridlinks all work fine. My gridlinks show two fields
>from the child table and when I click on the combo, they show in the
>popup list and the dataset edits fine and changes. However, the two
>fields don't show when the IB_LookupCombo is displayed on the form -
>only the first field shows. How can I get them to show all the time?

From what I can make of the above description, you're possibly trying to use the IB_LookupCombo for the wrong kind of relationship. What do you mean when you say "..don't show when the IBL_LookupCombo is displayed on the form..." ?

>Also, another related question, is it possible to set up gridlinks
>with two different tables with the columns in a foreign key

GridLinks is a property of the control, specifically a property of the drop-down list part of the control, which is an IB_Grid. In the case of this control, it enables you to have multiple fields in the list.

Data controls are set-driven. The datalinking between the set and the control is by way of the IB_Datasource. The only way you could have fields from multiple tables would be if the set were from multiple tables, i.e., a joined set or one with expression fields derived from subqueries.

>I want both fields to show in the popup, as well as the
>display as above.

You can't have multiple fields in the field part of the control, if this is what you meant. That's not how lookup controls work. The field part contains a unique key or, more usually in practice, the descriptive text associated with a unique key.

It's not at all clear to me what you are trying to do here....