IDL, SAFEARRAY of Structs
I am trying to get a typelib that describes an interface that contains a function that returns a SAFEARRAY of a struct.
VB Code:
struct TASK
{
long TaskId;
long ProcessId;
BSTR *Name;
};
blah blah blah
HRESULT AvailableTasks ( [in] long ThreadId,[in] long ActorId,[out,retval] SAFEARRAY(struct TASK)* );
This compiles with the warning: interface does not conform to [oleautomation] attribute . ..
I have tried it without the struct, and also using TypeDef for the struct. With the typedef approach a warning arises that states the syntax is incorrect without the /mktyplib203 switch.
I am correctly importing stdole2, too, and I am using the midl version 5.01.0164
No matter which way I try VB6 always comes back and says that this interface contains a type which it doesn't understand when I try to implement the interface even though it's object browser sees it just fine.
Any ideas; I'm having babies with this one :(