以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.com/bbs/index.asp)
--  专家坐堂  (http://foxtable.com/bbs/list.asp?boardid=2)
----  [求助]自定义登录窗口错误提示  (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=192507)

--  作者:lgj716330
--  发布时间:2024/6/27 12:12:00
--  [求助]自定义登录窗口错误提示
dr1 = dt.DataRows(0)
Dim pw As String = e.Form.Controls("PassWord").Value
Dim s As String = dr1("Password")
Dim pw2 As String = DecryptText(s,"a23","op#")
If pw = pw2 Then
    _UserName = UserName
    _UserGroup = dr1("Group")
    _UserRoles = dr1("Roles")
    If e.Form.Controls("CheckBox记住用户名").Checked = True Then
        SaveConfigValue("最后用户", _UserName & Vbcrlf & GetConfigValue("最后用户", "").Replace(_UserName,""))
    Else
        SaveConfigValue("最后用户", GetConfigValue("最后用户", "").Replace(_UserName,""))
    End If
    e.Form.Close
Else
    Messagebox.show("密码错误!", "提示", MessageBoxButtons.OK, MessageBoxIcon.Information)
End If

上述代码,当密码正确的时候没有错误提示,但密码错误点击确定的时候出现下面错误提示,怎么解决

图片点击可在新窗口打开查看此主题相关图片如下:微信图片_20240627120904.png
图片点击可在新窗口打开查看

[此贴子已经被作者于2024/6/27 12:12:46编辑过]

--  作者:有点蓝
--  发布时间:2024/6/27 12:14:00
--  
调试技巧:http://www.foxtable.com/webhelp/scr/1485.htm,看哪一句代码出错