Option Explicit
Private Sub Form_Load()
'工程->引用->选中Microsoft ActiveX Data Objects 2.8 Library
Dim shujukulianjie As New ADODB.Connection
Dim jiluji As New ADODB.Recordset
'连接数据库的代码段
shujukulianjie.Open "Provider=Microsoft.Jet.OLEDB.4.0;Persist Security Info=False;Data Source=" & App.Path & "/database/shujuku.mdb"
'自己改动一下上面的路径和文件名即可,其他的代码你不理解照粘贴无妨
'对xingmingbiao表进行查询操作
jiluji.Open "Select * from xingmingbiao",shujukulianjie
End Sub
==========================
http://www.bianceng.cn/Programming/vb/200812/11121.htm
http://zhidao.baidu.com/question/76929489.html?fr=qrl&cid=1073&index=2