Click here to Skip to main content
15,891,607 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
See more:
Hi, I have coded the following for loading the data of access in the drop down box and then show in the text boxes if selected from box but I am not getting data in the drop down box, pl help

What I have tried:

C#
con.Open();
mycmd = new OleDbCommand("select * from marksheet", con);
OleDbDataReader myread;
myread = mycmd.ExecuteReader();
while (myread.Read())
{textBox1.Text = myread[0].ToString();}
con.Close();
Posted
Comments
Richard MacCutchan 13-Feb-16 4:33am    
There is no dropdown in that code snippet. You are just repeatedly setting a textbox to a string.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900