There is a marshal class to manuplate all the interactions between C# and native:
It allows you to read the bytes and change to the type you want:
e.g:ITest is the interface, getMemory is the method, p is intptr which is assigned a wchar array in the native COM method. System.IntPtr p = Marshal.AllocHGlobal(4);
 ITest.getMemory(p);
 IntPtr p1 = (IntPtr)Marshal.ReadInt32(p);
 string i = Marshal.PtrToStringUni(p1); 
 Console.WriteLine("value is {0}",i);