asp.net2.0 GridView数据库捆定
Dim myConnection As OleDbConnection = New OleDbConnection("Provider=Microsoft.Jet.OLEDB.4.0;Data Source=E:\WebSite1\App_Data\用户信息.mdb")myConnection.Open()
Dim myCommand As OleDbCommand = New OleDbCommand("select * FROM 用户", myConnection)
GridView1.DataSource = myCommand.ExecuteReader()
GridView1.DataBind()
myConnection.Close()
上段代码是将数据库捆定到DataView中显示,但是显示的是所有的数据库的字段,怎样实现显示部分数据库的字段呢。