Did you consider using a simple free database (like MS Access) to save your data? DB generates unique ID for you and assigns it to every new record in a table...