Hi. I used Infopower for a long time but I can't afford to upgrade it to Delphi 2007. With Infopower I got TwwDBLookupCombo that allowed me to display a value, for example, a text ID, while updating the record with an internal ID. To place the component into the grid, I did something like dbgrid.setcontroltype(<fieldname> , <insertion type>, <component>).

I've spent some weeks by now trying to do something equivalent in Delphi 2007. I tried it with lookup fields and data fields, to no avail. Picklists don't work for me because I need to the internal ID, harder for a human being to choose, while showing a text ID. I'm using Delphi RAD 2007 with MySQL 5.0.45 and DBExpress (Delphi native driver) and all I get is a stack overflow.

I know it must be something really simple, but I can't find it.

Thanks for your attention.

Hi. I used Infopower for a long time but I can't afford to upgrade it to Delphi 2007. With Infopower I got TwwDBLookupCombo that allowed me to display a value, for example, a text ID, while updating the record with an internal ID. To place the component into the grid, I did something like dbgrid.setcontroltype(<fieldname> , <insertion type>, <component>).

I've spent some weeks by now trying to do something equivalent in Delphi 2007. I tried it with lookup fields and data fields, to no avail. Picklists don't work for me because I need to the internal ID, harder for a human being to choose, while showing a text ID. I'm using Delphi RAD 2007 with MySQL 5.0.45 and DBExpress (Delphi native driver) and all I get is a stack overflow.

I know it must be something really simple, but I can't find it.

Thanks for your attention.

Hi. I almost made it work (basically a matter of using table instead of query and a few other small things) but I have yet a problem. The picklist is showing the same values 7 times before showing the next value. I'm using a single field primary key so it can't be a matter of indices.

Any ideas?

TIA,

Eduardo

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.