Arrays Arrays Arrays (simple question)

rifter1818

Junior Contributor
Joined
Sep 11, 2003
Messages
255
Location
A cold dark place
Im a VB programmer who now has to learn c++ very quickly, how do i redimmension arrays and get the upper bound of an array in c++ preferably not .net specific (yes i know this is outside the usual bounds of this forum) Speaking of which any tutorials on c++ or specificly moving vb-> c++ would be greatly appreciated.
 
arrays in C++ have fixed size. if you need to redim an array, you must create another array with the size you need, then move the old array items to the new one and then delete the old one. (there's a way to not need to MOVE and DELETE, but that involves more pointer stuff than i think u'd like)
 
Back
Top