I tried the GetSafeArrayPtr()
method which returns a LPSAFEARRAY* that a typedef defined as:
typedef /* [wire_marshal] */ SAFEARRAY *LPSAFEARRAY;
I thought I would be able to directly assign this to a SAFEARRAY* variable but the compiler gives this error:
error C2440: '=' : cannot convert from 'LPSAFEARRAY *' to 'SAFEARRAY *'
I found this strange. What am I doing wrong here?
PS: I am doing this inside a C++/CLI dll (if that is of any relevance).