|
Dim strSql As String
Dim rs As New ADODB.Recordset
strSql = "select * from tblUser where UserName='" & Me!TxtUname & "'"
Set rs.ActiveConnection = CurrentProject.Connection
rs.Open strSql, , adOpenStatic, adLockReadOnly
If rs("assword") = Trim(Me!TxtWord) Then
rs.Close
strSql = "select * from tblLogin"
rs.Open strSql, , adOpenDynamic, adLockOptimistic
rs.AddNew
rs("BeginDate") = Now()
rs("LoginName") = Me!TxtUname
rs.Update
rs.Close
Set rs = Nothing
DoCmd.Close请教这句是什么意思??? 是用更新查询吗?
|
|