Adding Points to a Point Array

Hello, I have a point array (array<Point>^ pa) to which I want to add more points. Is this posible

With Thanks,
                    Gal Beniamini.


Answer this question

Adding Points to a Point Array

  • Vytas

    In .NET 2.0, you can use Array::Resize() to add extra points to the array. However, take note of the documentation of Resize:

    "This method allocates a new array with the specified size, copies elements from the old array to the new one, and then replaces the old array with the new one."

    If you're adding Points to the array in a performance-critical, deeply-nested loop, you can avoid performance degradation by converting the array to an ArrayList or List<> beforehand (or just use a ArrayList/List<> throughout).

     



  • Adding Points to a Point Array