Mindi Posted May 19, 2005 Posted May 19, 2005 If I delete all of the records in a table I want to reset the Auto-Enter Serial Number ID field to 1 (one). Also, if I only delete some of the records I would like the serial number to be reset to the max of the ID + 1. I feel like I saw this script somwhre but cannot seem to locate it.
J__ Posted May 19, 2005 Posted May 19, 2005 You did see it somewhere - in the help the script is "Set Next Serial Value" From fm7 help: Go to Record/Request/Page [Last] Set Next Serial Value [Table1::Invoice ID; Table1::InvoiceID + 1] hope that helps, sincerely J__
TereLavin Posted May 19, 2005 Posted May 19, 2005 you can try use a count: SerialNumber, calc, = Count+1 Count, number, =0 and a scritp "Reset"= Set Field Count="0" your serial number begin in 1, and will being increased, when you reset by the script, has a new begin to 0. Just try. Tere Lavin [email protected]
TereLavin Posted May 19, 2005 Posted May 19, 2005 sorry, you need 2 scripts to make the count. or when you make a new record, on the new record script add, SetField(Count)=Count+1 and will being increased too. i hope help you. Tere Lavin
Recommended Posts
This topic is 7196 days old. Please don't post here. Open a new topic instead.
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now