Forums

Auto Number

dharbottle 28 Feb, 2008
I am trying to create a purchase order number request form for our office.

Our accounts department require all purchases to have a order number. I am wanting for the form to sequentially generate a number, store it with the form, but then be able to feed back this number in the on submit message.

The user will enter the relevant details for the purchase they would like to make, what department it is getting spent from etc and then hit submit. The form will then issue them a Number which they will quote to the businesses we have accounts with. Our finance officer will then cross check all the monthly statements (with accompanying order numbers) with the requests made on the website.

Does this make sense?

What I hope the form will do is: send the purchase order number, purchase details, and purchasee to an email address and store in the database.

Does each submission generate it's own ID number? Can this be displayed?

Dan
GreyHead 28 Feb, 2008
Hi Dan,

Yes, this can be done. If you Create a table and save the form data to a database table then you will have a unique record id that you can use as a PO number. In the DataView Fields tab you can change the Main string ref to read 'PO number #n' instead of 'Record #n'.

There is one technical problem which is that that database record is almost the last thing created so you don't know the record id when the email is sent. There is a workaround for this in the forums here. If you can't find it let me know and I'll have a dig (it ought to be in the FAQs but I don't think it's made it there).

Bob
This topic is locked and no more replies can be posted.