Hi,


I'm not a very well C++ programmer, and I have the following problem:

I've a VB activex with successfully is merged with my C++ project. So far no problem. But now I want to invoke a method of the VB ActiveX, the method looks like:


virtual /* [id] */ HRESULT __stdcall GetValue(

/* [in] */ VARIANT sCategory,

/* [in] */ VARIANT sName,

/* [defaultvalue][optional][in] */ VARIANT sDefault,

/* [retval][out] */ VARIANT __RPC_FAR *__MIDL_0015) = 0;


The method call would be something like:


mGlobals->GetValue(sCategory, sName, sDefault, RetVal);


My problem is type casting between the VARIANT's and some CString's I have.

Can somebody give me an example of how the convert VARIANT's to CString's or any other type I can better use. (I can use some tips on with type to use for strings).


Thanks in advance.


Regards,

Berthold Hutten