IMetaDataEmit::SetPinvokeMap Method

 

Sets or changes features of a method's PInvoke signature, as defined by a prior call to IMetaDataEmit::DefinePinvokeMap.

HRESULT SetPinvokeMap (   
    [in]  mdToken      tk,   
    [in]  DWORD        dwMappingFlags,  
    [in]  LPCWSTR      szImportName,   
    [in]  mdModuleRef  mrImportDLL   
);  

Parameters

tk
[in] The mdToken to which mapping information applies.

dwMappingFlags
[in] Flags used by PInvoke to do the mapping. This is a bitmask of CorPinvokeMap values.

szImportName
[in] The name of the target export in the native DLL.

mrImportDLL
[in] The mdModuleRef token for the target unmanaged DLL.

Platforms: See System Requirements.

Header: Cor.h

Library: Used as a resource in MSCorEE.dll

.NET Framework Versions: Available since 1.0

IMetaDataEmit Interface
IMetaDataEmit2 Interface

Show: