I have created CComSafeArray object having 32 elements using the following statements. But after some operations I came to know that I need only 3 elements in the safe array. Is it possible to change the number of elements 开发者_如何学Goin the safe array after creating it?
CComSafeArray<VARIANT> x(32);
Are you by any chance looking for the CComSafeArray::Resize()
member function?
http://msdn.microsoft.com/en-us/library/9758bsfw(v=vs.71).aspx
精彩评论