hmm.. apparently I can only set a field ID when I want to retreive a value from a recordset.
I mean this:
that dr.GetString() cannot accept a field name instead of an integer. Is there any other function or way to reference a field by its name, instead of by its number?
I mean this:
Code:
while (dr.Read())
{
this.cmbCity.Items.Add(dr.GetString(0));
}
that dr.GetString() cannot accept a field name instead of an integer. Is there any other function or way to reference a field by its name, instead of by its number?