Board index » delphi » DB Dropdown Combo question

DB Dropdown Combo question

Hi:
Can anyone tell me why I can't get the display value to show in the text
box portion of a DB Dropdown combo ? I have an invoice table (dbase)
that contains a customer number. The lookup source for the combo box is
the customer table. As I scroll throught the invoices, nothing appears
in the text portion of the combo box. BUT if I click the combo box to
open it, the correct name is highlighted (selected) in the list. Is
there a "secret" I'm not aware of to get the name to display in the text
box portion ??
Thanks,
Ken
 

Re:DB Dropdown Combo question


Quote
On Mon, 05 Feb 1996 18:36:25 -0500, Ken <Ken...@ix.netcom.com> wrote:
>Hi:
>Can anyone tell me why I can't get the display value to show in the text
>box portion of a DB Dropdown combo ? I have an invoice table (dbase)
>that contains a customer number. The lookup source for the combo box is
>the customer table. As I scroll throught the invoices, nothing appears
>in the text portion of the combo box. BUT if I click the combo box to
>open it, the correct name is highlighted (selected) in the list. Is
>there a "secret" I'm not aware of to get the name to display in the text
>box portion ??

I have had similar problems in the past.  From memory it is because
the lookupindex value in the combo box is not the same as the index in
the lookup table.  

Sean

Re:DB Dropdown Combo question


Quote
s...@crm.co.nz (Sean Cross) wrote:
>On Mon, 05 Feb 1996 18:36:25 -0500, Ken <Ken...@ix.netcom.com> wrote:
>>Hi:
>>Can anyone tell me why I can't get the display value to show in the text
>>box portion of a DB Dropdown combo ? I have an invoice table (dbase)
>>that contains a customer number. The lookup source for the combo box is
>>the customer table. As I scroll throught the invoices, nothing appears
>>in the text portion of the combo box. BUT if I click the combo box to
>>open it, the correct name is highlighted (selected) in the list. Is
>>there a "secret" I'm not aware of to get the name to display in the text
>>box portion ??
>I have had similar problems in the past.  From memory it is because
>the lookupindex value in the combo box is not the same as the index in
>the lookup table.  

I had this problem as well but my mistake was more simple. I didn't
HAVE an index assigned for either table(which you must). Also, on some
occasions, I had to fiddle with the Autocalc (to false) though this
wasn't consistent. In my example also, Readonly must be false on the
datasource table, though it can be true on the Lookupsource.

Other Threads