If you really mean "reset" then you have to store a variable in non-volatile memory, the EEPROM for example.
I think that he simply wants to automatically create a new filename at every startup. To do this he generates a new filename by incrementing a counter until the filename does not already exists on the SD card.