各位好啊:
我想用一个dropdownlist控件邦定数据库中的表,但不知怎么邦定.
以下是我写的代码,但不能实现.请大家帮看看.谢谢!
Imports System.Data
Imports System.Data.oledb
......
Dim cnn As New OleDbConnection("provider=microsoft.jet.oledb.4.0;data source=D:\mjch2008\fsx.mdb")
cnn.Open()
Dim adt As New OleDbDataAdapter("select * from link order by tID asc", cnn)
Dim ds As New DataSet
adt.Fill(ds, "link")
DropDownList1.DataSource = ds
DropDownList1.DataMember = "link"
DropDownList1.DataBind()
dropdownlist控件邦定数据库表的问题!!!