How do I build a vector of system::drawing::rectangle in c++? I tried vecor of std but got an error message that mixed types are not supported. W开发者_运维百科hat can I do?
You can use the List<T>
class.
You can use an Array or List or other .Net collection.
Example:
List<System::Drawing::Rectangle>^ rectangles = gcnew List<System::Drawing::Rectangle>();
Note - If you are using VS2010 you can simplify this to:
auto rectangles = gcnew List<System::Drawing::Rectangle>();
精彩评论