COMException "Biblioteca não registada". enquanto estiver usando o Sistema.DirectoryServices
-
09-06-2019 - |
Pergunta
Eu tenho apenas começou recebido o seguinte erro no meu windows aplicações de formulários em .NET 2 framework no windows 2000 quando utilizar System.DirectoryServices
.
{System.Runtime.InteropServices.COMException}
System.Runtime.InteropServices.COMException: {"Library not registered."}
_className: Nothing
_COMPlusExceptionCode: -532459699
_data: Nothing
_dynamicMethods: Nothing
_exceptionMethod: Nothing
_exceptionMethodString: Nothing
_helpURL: Nothing
_HResult: -2147319779
_innerException: Nothing
_message: "Library not registered."
_remoteStackIndex: 0
_remoteStackTraceString: Nothing
_source: Nothing
_stackTrace: {System.Array}
_stackTraceString: Nothing
_xcode: -532459699
_xptrs: 0
Source: "System.DirectoryServices"
StackTrace: " at System.DirectoryServices.DirectoryEntry.Bind(Boolean throwIfFail)
at System.DirectoryServices.DirectoryEntry.Bind()
at System.DirectoryServices.DirectoryEntry.get_AdsObject()
at System.DirectoryServices.DirectorySearcher.FindAll(Boolean findMoreThanOne)
at System.DirectoryServices.DirectorySearcher.FindAll()
Eu re-instalado o framework e re-registrado activeds.dll
no entanto, isso não resolveu o problema.Eu estou supondo que eu preciso encontrar outra dll e registrá-lo novamente, no entanto, não está claro qual dll este seria.
Solução
Depois de ter usado Refletor para ter um rápido pico de Serviços de Diretório de código, ele se parece com o Active Directory Service Interfaces de instalação pode ser destruída.
Você pode baixar a versão 2.5 do Technet embora eu não tenho certeza se é a versão mais recente ou se ele funciona com o Windows 2000.
Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow