修改用户密码~!
运行后,指到:conn.Execute sql,提示“对象关闭时,不允许操作”。请问我这里有什么问题~!谢谢Private Sub cmd1_Click()
Dim p As String
Dim p2 As String
Dim sql As String
p = InputBox("请输入新密码")
p2 = InputBox("请再次输入新密码")
If p <> p2 Or pass = "" Then
MsgBox "输入有误"
Exit Sub
End If
sql = "update 用户 set 密码='" & pass & "' where 用户名='" & UserName & "'"
conn.Execute sql
End Sub