tomekalaj

tomekalaj

  • NA
  • 16
  • 0

textBox KeyPress event, connect with listBox

Mar 29 2005 8:34 AM
I have listBox and I Fill him with some values ( oleDbConnection1.Open(); OleDbDataAdapter DAProdukt = new OleDbDataAdapter("select ProduktID,ProdName FROM Producti",oleDbConnection1); DataSet DSProdukti = new DataSet(); DAProdukt.Fill(DSProdukti); listBox1.DataSource = DSProdukti.Tables[0]; listBox1.DisplayMember = "ProdName"; listBox1.ValueMember = "ProduktID"; ). Is it possible for example to start write in one textBox and in that textBox.Text to show the value from listBox.DisplayMember, who have the same name before I write all name? If is not possible than how can I do that with comboBox1 when I start writing in him automatically to show the name from comboBox1.DisplayMember before I write all name? Thanks!!

Answers (2)