December 18th, 2009, 10:43 AM
COleSafeArray with ints and strings
is it possible to set different data types in a COleSageArray?
In the code above I have a COleSafeArray of Strings. But I need the first and the third column to be a integer-value (VT_R8).
numElements= rowCount; //Number of rows in the range.
numElements= colCount; //Number of columns in the range.
saRet.Create(VT_BSTR, 2, numElements);
Tanks in advance
December 18th, 2009, 11:06 AM
Re: COleSafeArray with ints and strings
I'm not sure I'm reading this right, but if you have more than one type, it is no longer an array. Perhaps you need a one-dimensional array of struct where the struct has various types as needed.
Click Here to Expand Forum to Full Width
This a Codeguru.com survey!