I am developing a C++/Qt application that communicates with an ActiveX server. I try to use a function that returns a reference to an array of floats as a parameter. The function prototype is:
Frequencies([in, out] SAFEARRAY(float)*)
My code is:
QList<QVariant> variantList;
object->dynamicCall("Frequencies(QList<QVariant>&)", variantList);
But unfortunately I have the following error: Type Mismatch in Parameter. Pass an array of type string or real.
After reading this document I also tried QList<QString>&
and QList<float>&
with no success.
The documentation of the ActiveX server says: Use a safearray of strings (VT_BSTR) or reals (VT_R8 for double or VT_R4 for float).
Any idea?
Thanks!