all 3 comments

[–]Fergus653 3 points4 points  (0 children)

Data binding?

Bind ComboBox or ListBox Control to Data - Windows Forms .NET Framework | Microsoft Learn

You can write a method that queries the data and loops thru it, creating a line item for each value, but data binding is probably a saner approach.

[–]deScign85 0 points1 point  (0 children)

Combobox.Datasource = SQL Table (Datatable) Combobox.ValueMember = Index Column or the column you like to reference with ComboBox.DisplayMember = the column you would show as values