Board index » delphi » Populating combobox items from a DB?

Populating combobox items from a DB?

Hi.

I'm trying to populate a combobox's selection items from a database table. I
have a table (paradox7) with the fields "Type, subtype, label, year", and
based upon the criteria Type, Subtype and Year, I want the combo box to have
the item selections for Label.

Is there any way to do this? I have tried everything I can think of, but
haven't managed to
access the return buffer from a query...

Arvind

 

Re:Populating combobox items from a DB?


while not Query1.EOF do
begin
  ComboBox1.Items.Add(Query1Label.Value);
  Next;
end;

Paul / ColumbuSoft
www.columbusoft.com

Quote
Arvind Knudsen <arvindknud...@home.com> wrote in message

news:M%3E5.295291$i5.4203191@news1.frmt1.sfba.home.com...
Quote
> Hi.

> I'm trying to populate a combobox's selection items from a database table.
I
> have a table (paradox7) with the fields "Type, subtype, label, year", and
> based upon the criteria Type, Subtype and Year, I want the combo box to
have
> the item selections for Label.

> Is there any way to do this? I have tried everything I can think of, but
> haven't managed to
> access the return buffer from a query...

> Arvind

Re:Populating combobox items from a DB?


Try using a dbCombobox and set the databasename to the databasename and the
fieldname to the fieldname u want to display

Other Threads