Dim rst As ADODB.Recordset Dim strSQL As String strSQL = "select * from 你的表名 where 姓名="李四" " Set rst = New ADODB.Recordset rst.Open strSQL, CurrentProject.Connection, adOpenKeyset, adLockOptimistic msgbox"年龄是:"& rst!年龄 &"" rst.Close Set rst = Nothing