These forums are now Read Only. If you have an Acrobat question, ask questions and get help from one of our experts.

Auto poulating a number on a form

jojo1974
Registered: May 4 2010
Posts: 5

Hi,

I am hoping someone can help.

I am using Live Cycle to create a form that requires a unique number but having difficulty working out how to auto number the form.

For example the first form will be numbered 752001 and then any subsequent times the form is opened it will add 1 so i.e 752002 752003, so on and so forth.

I am new to Live Cycle as designer software but have done lots of VB coding etc on other programs so happy to add script if anyone knows what and where it should go.

Any help will be muchly appreciated.

Kind Regards

My Product Information:
LiveCycle Designer, Windows
--SID--
Registered: May 4 2010
Posts: 31
One way to do this, would be to create a schema or associate the form with an external DB, like an excel file. The external file can contain the latest no. of the form lets say '5'.

next time when the form is opened, you can put a script at the initialize event, so that the same value is picked from the excel, and incremented by 1.

~~ S I D ~~

jojo1974
Registered: May 4 2010
Posts: 5
Would you have any idea what the script would need to be?
--SID--
Registered: May 4 2010
Posts: 31
When the form is saved, this no. would appear in a read only text field , right ?
now when the form is opening next time, the text field will get populated with the same old value, and then before it renders, you can apply the script.

textfield.rawValue = textfield.rawValue+1

so in theory the field populated with the same value as last time, but before it got visible, the initialize event would fire, and that would increment the existing value by one.

~~ S I D ~~