' For more information about handling COM exceptions, see Handling Errors. 'NewUser.MoveTo(New DirectoryEntry("LDAP://OU=Temp,DC=domain,DC=com"))Ĭatch InvOpEx As InvalidOperationException The same applies for ADS: Filters in which DN attributes are searched with wildcards do not work. NewUser.MoveTo(New DirectoryEntry(movetoldap)) According to these matching rules you cant use wildcards in LDAP filters for attributes containing LDAP distinguished names (attributes with DN-string syntax / ADSI attribute data type ADSTYPEDNSTRING 1). ' Use the MoveTo property to define the new container you want to move the object to.ĭim movetoldap As String = "LDAP://ou=users, ou=" & vDirectorate & ", " & "ou=New OU, ds=domain, ds=com" The query finds the User OK but wont do the move as it has a problem with the selected ITEM "ĭim UserADString As String = result.Path()ĭim NewUser As New DirectoryEntry(UserADString) ![]() Hi thanks for your help, I did find a Microsft Example, which I can get working if I add the LDAP path in manually, but if I try to use a STRING value it fails, as I want the Users to select a value from a dropdown list that is populatedįrom the OU NAmes (Finance, Engineering, etc)
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |