tgd

tgd

  • NA
  • 14
  • 0

What's wrong with this? (ComboBox Filling)

Oct 14 2003 4:53 AM
Some help, please... SqlCommand cmd = GlobalVar.Connection.CreateCommand(); cmd.CommandType = CommandType.Text; cmd.CommandText = "SELECT CurrSymb FROM GNCurrency ORDER BY CurrSymb"; SqlDataAdapter da = new SqlDataAdapter(); DataSet ds = new DataSet(); da.SelectCommand = cmd; da.Fill(ds, "Moneda"); cboValuta.DataSource = ds; for(int i = 0; i < ds.Tables["Moneda"].Rows.Count; i++) { cboValuta.Text = ds.Tables["Moneda"].Rows[i]["CurrSymb"].ToString(); }

Answers (4)