Showing posts with label AutoIncrementSeed. Show all posts
Showing posts with label AutoIncrementSeed. Show all posts

Monday, May 25, 2009

Behaviour of the AutoIncrementSeed property

Oftentimes we will need to reset the seed to 0 when refilling a DataTable with new data. Due to the implementation of set_AutoIncrementSeed, we cannot just set AutoIncrementSeed = 0. We must do the following:
AutoIncrementStep = -1;
AutoIncrementSeed = 1;
AutoIncrementStep = 1;