Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

What causes "The type library importer could not convert the signature for the member" warnings?

I occasionally get a number of warnings in my web app:

Warning 5   The type library importer could not convert the signature for the member 'ADS_OCTET_STRING.lpValue'.    
Warning 6   The type library importer could not convert the signature for the member '__MIDL___MIDL_itf_ads_0000_0002.lpValue'. 
Warning 7   The type library importer could not convert the signature for the member 'ADS_NT_SECURITY_DESCRIPTOR.lpValue'.  
Warning 8   The type library importer could not convert the signature for the member '__MIDL___MIDL_itf_ads_0000_0003.lpValue'. 
---- snip ----
Warning 33  The type library importer could not convert the signature for the member 'tagARRAYDESC.rgbounds'.   
Warning 34  At least one of the arguments for 'ITypeComp.RemoteBind' cannot be marshaled by the runtime marshaler.  Such arguments will therefore be passed as a pointer and may require unsafe code to manipulate.

There doesn't seem to be anything actually wrong, and restarting Visual Studio seems to make them go away. What causes this, and is there any way to fix it short of restarting?

like image 399
chris Avatar asked Nov 04 '10 19:11

chris


2 Answers

Create your own interop assembly like this (ActiveDs for example):

tlbimp activeds.tlb /out:c:\temp\Interop.ActiveDs.dll /silent

Reference this instead of ActiveDs, and the errors dissappear.

like image 72
Flores Avatar answered Nov 02 '22 09:11

Flores


Did you try this? Seems to be the same error you're having.

http://social.msdn.microsoft.com/Forums/en-US/clr/thread/37654e9b-e484-43dc-8e3b-9f6344d42055/

like image 37
Simon Halsey Avatar answered Nov 02 '22 09:11

Simon Halsey