下面的方法有点怪。首先在VB的引用对话框中选择“Microsoft DAO 3.xx Object Library”（xx的具体值和你的VB版本有关） 
     Dim acc As Access.Application 
     Dim db As DAO.Database 
     Dim strDbName As String 
     strDbName = "D:\ComponentSource\DBFiles\CSMain\CSMain.mdb" 
     Set acc = New Access.Application 
     acc.Visible = True 
     Set db = acc.DBEngine.OpenDatabase(strDbName, False, False, ";PWD=outlook") 
     acc.OpenCurrentDatabase strDbName 
     db.Close 
     Set db = Nothing 
<END>
