Dim cnn As New ADODB.Connection
Dim rst As New ADODB.Recordset
Dim s As String
Dim st As String
st = App.Path & "\NWIND.MDB"
s = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & App.Path & "\data.db;jet oledb:database password=123456"
cnn.CursorLocation = adUseClient
cnn.Open s
Set rst = New Recordset
rst.Open "表", cnn, adOpenStatic, adLockOptimistic