Assuming 2 polygons on a map, when using DeleteMapPolygon, any further calls made to UpdateMapPolygon will fail because ItemIndex then becomes wrong.
ItemIndex is populated when creating the Polygon (TPolygonCount which btw, isn't the best name for a variable as T normally is used for classes). If you delete Polygon 0, the ItemIndex of the remaining polygon (1) remains 1 (although we now only have 1 polygon and it should now be zero).
I was going to hack it and change it on the fly but we can't change ItemIndex (as it is a read-only property).
What can I do?