Hi Bill,
Not as simple as I would have hoped, but I had a customer ask for this exact same thing this morning, so I created a setup that seems to work.
EDIT: After further testing, I realized my first method could create duplicate numbers (if a 2nd form was started before the 1st was submitted), so I've switched things up so all the numbering happens with Rules Service Tasks. This means the auto number isn't shown on the first form, but should prevent duplicates in 99% of cases. Instructions below have been updated.
NOTE: There is still a small chance of duplicate numbers being created if two forms are submitted at the same time (2nd submission while the 1st is between the SELECT and the INSERT).
These instructions are for Cloud, but I believe they should be adaptable to On-Prem.
Auto Number Field in Forms
- Create a single column Lookup Table with a single value to start, either 0 if you wish the auto number to start at 1, or your starting number - 1 (the table holds past values)

- Create a Select rule for the lookup table selecting the single column, with the Function set to 'Max' and the Quantifier set to 'Distinct' (this selects the highest value in the table)

- Create a Formula that adds 1 to an inputted number

- Create a Insert rule that takes a number and inserts it in the Lookup Table

- Create two fields in the form: one called 'Last_Auto_Number' (which you will want to hide) and one to hold the auto number you want displayed/attached to the form
- Use three Rules Service Tasks placed after the form to run the Select query, the Formula, and the Insert Query (in that order). Set the Select query to write the value from the table to Last_Auto_Number, set the Formula to input the Last_Auto_Number and output to your displayed auto number field, and the Insert query to write the displayed auto number field value (the value attached to the current form/process) to the Lookup Table



