i have a class with a table inside
the table takes memory with new
in some cases the table could take a bigger size and i want to reallocate the memory without loosing what i have inside
I don't know what copy is doing (I hope it creates elements as well as copy values), but once you've filled in temp, you just need to release Data, then assign temp to Data (not copy the content all over again).