Combobox in run time

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

i need to know how to make binding for the data for a Combobox in run time
from the DB

i wrote that

this.CFaculities.DataBindings.Add(new Binding("Text" ,DS_H.Tables[0]
,"F_name"));

where F_name is the column in the table
but it tells me it can't bind the data to column F_name ??
is there any extra statemnts should be added , plz a sample code
help :)
 
comboBox1.DataSource = ds1.Tables[0];// TableName

comboBox1.DisplayMember = "CategoryName"; // ColumnName
 
Back
Top