问题
I want to have a text box have the current document_id
displayed. Is there an XPath expression to get that?
回答1:
The following XPath returns the current document id, the same that you see on the URL on the edit page you get by clicking on a form instance in the summary page.
xxforms:instance('fr-parameters-instance')/document
Note however that if you use this in a calculated expression, for new forms, the value won't show until a change was done in the form (e.g. users entered a value in a field).
来源:https://stackoverflow.com/questions/5173063/orbeon-forms-find-current-document-id