OpenDSObject的错误代码和描述列表

时间:2014-05-06 14:40:40

标签: vbscript asp-classic ldap

我有以下内容,但是如果可能的话,我希望有完整的代码列表及其详细说明。

例如用户名是否存在?密码错了吗?

Set oADsObject = oADsNamespace.OpenDSObject(strADsPath, strUserName,strPassword, 0)
Select Case Err.number
Case 0
  ' Success
    Session("Auth") = "YES"
Case -80070775
  'Locked
    errorMSG = "Account has been locked"
Case -2147943726, -2147023570, -2147024810, -2147023677, -2147022694
  ' Invalid
    Session("Auth") = "NO"
    errorMSG="Invalid details"
Case -2147023565
  ' Disabled
    Session("Auth") = "NO"
    errorMSG = "Disabled account"
Case -2147022987
  'Loceked
    Session("Auth") = "NO"
    errorMSG = "Locked Account"
Case -2147022989, -2147023541, -2147023688
  'Password expired
    Session("Auth") = "NO"
    errorMSG = "Password Expired"
Case else
  'Something else
    Session("Auth") = "NO"
    errorMSG = Err.Number
end select

0 个答案:

没有答案