Hi. I have bitten off more than I can chew! I need to use the MS LDAP API rather than the DirectoryServices namespace (because of a non-standard directory implementation. The API defines an LDAP struct, which I need to translate to C# types, but I am having problems getting the method signature to work since the dll function returns a pointer to this struct.
Here is the function for C/C++: LDAP * ldap_init(PCHAR HostName, ULONG PortNumber); The documentation suggests that I should marshal the return type as UnmanagedType.LPStruct, but I get an exception saying the method signature is not PInvoke compatible. Any help appreciated. KH _________________________________________________________________ Send and receive Hotmail on your mobile device: http://mobile.msn.com You can read messages from the DOTNET archive, unsubscribe from DOTNET, or subscribe to other DevelopMentor lists at http://discuss.develop.com.