Hello friends,
i have table name called branch which has branchid,brachname columns. i want to retrieve branchname value to the datarow class using sqldatareader.and then this value is need to bind with combobox text . please help me.
Loading
Atul KumarPosted Jul 27, 2012, 5:07 AM
Atul KumarPosted Jul 27, 2012, 4:52 AM
List
if (reader.HasRows)
{
while(reader.Read())
{
branchNames.Add(reader["branchName"].ToString());
}
}
dataGrid.DataSource = branchNames;