Click here to Skip to main content
14,451,614 members
Rate this:
Please Sign up or sign in to vote.
See more:
Hi,

I am using C++ DLL from my VB.NET project using DLLImport. But I have not experience of how to handle the pointer in VB.NET.

The C++ function call & declaration is a below.

EXTERNC T_PDU_ERROR PDUGetModuleIds(PDU_MODULE_ITEM **pModuleIdList)

where 

typedef struct {
T_PDU_IT ItemType; 
UNUM32 NumEntries; 
PDU_MODULE_DATA *pModuleData; 
} PDU_MODULE_ITEM;

typedef struct {
UNUM32 ModuleTypeId; 
UNUM32 hMod; 
CHAR8 *pVendorModuleName; 
CHAR8 *pVendorAdditionalInfo; 
T_PDU_STATUS ModuleStatus; 
} PDU_MODULE_DATA;


Please tell me how to use the C++ DLL from my VB.NET application.

Thanks in advance
Posted
Updated 2-Feb-10 10:11am
v2
Rate this:
Please Sign up or sign in to vote.

Solution 1

   
Rate this:
Please Sign up or sign in to vote.

Solution 2

Thanks ,but I need that how to use with Structure Pointer
   
Rate this:
Please Sign up or sign in to vote.

Solution 3

Take a look at the Pinvoke[^] site. It does not have an entry for your specific case, but you can figure out what you need to do from the other samples quite easily.
   

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)




CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100