毕业论文论文范文课程设计实践报告法律论文英语论文教学论文医学论文农学论文艺术论文行政论文管理论文计算机安全
您现在的位置: 毕业论文 >> 课程设计 >> 正文

班级通讯录管理系统

更新时间:2009-6-3:  来源:毕业论文

班级通讯录管理系统
修改密码

Private Sub 命令6_Click()
Dim rs As New ADODB.Recordset
Dim rss As New ADODB.Recordset
Dim x As String
Dim conn As New ADODB.Connection
Dim strql As String
Dim n As Integer
strql = "select count(用户.用户名) from 用户 where 用户名=" & "'" & text0 & "'"
strql = strql & "and 密码 =" & "'" & text2 & "'"
x = "update 用户 set 用户.密码=" & "'" & text10 & "'" & "where 用户名=" & "'" & text0 & "'"
Set conn = CurrentProject.Connection
rs.Open strql, conn, adOpenKeyset, adLockOptimistic
n = rs(0)
If n = 1 Then
rss.Open x, conn, adOpenKeyset, adLockOptimistic
MsgBox "修改成功"
DoCmd.Close
Else
MsgBox "原密码错误"
End If
End Sub
密码检查Private Sub 命令4_Click()
Dim rs As New ADODB.Recordset
Dim conn As New ADODB.Connection
Dim strql As String
Dim n As Integer

strql = "select count(用户.用户ID) from 用户 where 用户名=" & "'" & text1 & "'"
strql = strql & "and 密码 =" & "'" & text2 & "'"
Set conn = CurrentProject.Connection
rs.Open strql, conn, adOpenKeyset, adLockOptimistic
n = rs(0)
If IsNull(text1) Or IsNull(text2) Then
 MsgBox "用户名或密码不能为空"
Else
 If n = 1 Then
  'DoCmd.OpenForm "主窗体"
  DoCmd.RunMacro "宏1"
  DoCmd.Close acForm, "窗体4"
  Else
  MsgBox "密码不正确"
  End If
 End If
End Sub436

班级通讯录管理系统下载如图片无法显示或论文不完整,请联系qq752018766
设为首页 | 联系站长 | 友情链接 | 网站地图 |

copyright©751com.cn 辣文论文网 严禁转载
如果本毕业论文网损害了您的利益或者侵犯了您的权利,请及时联系,我们一定会及时改正。