查询错误
Private Sub Command1_Click()Set g_ws = DBEngine.Workspaces(0)
Set g_db = g_ws.OpenDatabase(App.Path + "\出差登记表.mdb")
'strDataSource = "select * from 信息办出差登记表 where 姓名='Text1.Text'"
aa = Text1.Text
MsgBox aa
strDataSource = "select * from 信息办出差登记表 where 信息办出差登记表.姓名='aa'"
Adodc1.ConnectionString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & App.Path & "\出差登记表.mdb;Persist Security Info=False"
Adodc1.CursorLocation = adUseClient
Adodc1.CommandType = adCmdText
Adodc1.RecordSource = strDataSource
Adodc1.Refresh
End Sub