Error 0x80005000 using LDAP in VBScript

Logon Error

While rolling out a new logon script, I started getting reports of an error message like this one showing up. Error 0x80005000 with a source of (null) isn’t particularly helpful.  The particular section of code referenced in the error dealt with pulling a user’s group membership from LDAP, and mapping drives accordingly.

After stepping through the script, I found that it was bombing out on a group with a forward slash (/) in the name.  The / was throwing off the LDAP query, since it is a reserved separator character.  There are 2 fixes for this.  You can either do a substring replace, and replace ‘/’ with ‘\\/’ (yes – double backslash slash), or you can do what I did and just rename the group in ActiveDirectory to not contain a /.

Comments are closed.