Online Form - Unique Auto-Generated Form Number

Hello,

I have a registration form that I would like an auto-generated number based on a time stamp. This number should be unique and not duplicatable, that’s why I ask for it to be generate using time.
Is this possible to do within LibreOffice Writer? These forms will be exported to a PDF format to be uploaded to our website. Ideally, this number should auto generate as soon as the form is opened and be viewable when the form has been printed. It does not matter if the form is closed and a new form is opened using a new auto generated number. As long as any time a form is opened, a new number is generated.

Please advise if this is feasible.

Thank you

This specification is outside the scope of present Writer which aims at helping to format and layout a “literary” document. Laying out a form is a border case, at the boundary with drawing applications, formatting features being used for text contents commenting on the fields usage.

What you request is a specific “initial value” for a field. This is user-dependent; there is no convention nor normative rule about it. Consequently you must implement it yourself. This can be done, in a limited way, with a macro (though to make sure the id is unique you probably need to check it against a database). To protect against alteration, this id should probably contain redundant information (like a CRC or a hash) and, again, this is user-specific.

Short answer: No.

Longer version: You may construct a macro for writer, but the features of LibreOffice are not exportable to the pdf.
You may develop a Javascript-Macro and embedd this in your pdf, but LO will not help there. (Scribus can integrate you script, but you have to develop this yourself)

And if you want to try this, check if the pdf-readers of your users will support this. In my company most workstations have “simple” pdf-readers (without scripting) for improved security…