I want to add all the Records in my database in a list box (Book name), However nothing is adding to the listbox
Code:
cmd.Connection = cn
cmd.CommandType = CommandType.Text
cmd.CommandText = " select BookName from Book "
rdr = cmd.ExecuteReader
Do While rdr.Read
cbdvuser.Items.Add(rdr.Item("BookName"))
Loop
cn.Close()