IPFDocument formatter
This formatter makes a document available for download or upload. Use this for handling attachments in a data source or to provide access to the document itself in the custom scripting. The data value is the document. The data value must be of type IPFDocumentl to work with this formatter.
For information about a specific option in the FDF Editor, click in the field to see the context-sensitive help.
When Upload is set to true, the Field Display Format and Display Data Property values are required.
If the document field is clickable and the user clicks the field, the file chooser is presented, allowing the user to upload a document. If the upload is successful, the Click handler is run and the document is available as the data value of type IPFDocumentI.
If the data value is in a bound property, the record is not automatically saved, so the save must be handled by the Click handler or later as appropriate.
If the data value is in an unbound property or component, the document must be moved to a bound property of IPFDocumentI at some point before it can be saved to a data source.
Currently documents can come from any component with a value of type IPFDocumentl.
The IPFSPAttachments property is of type IPFDocumentCollectionI; thus
you can get it with
.GetValue(Of IPFDocumentCollectionI)()
.
All browsers support the functionality described here. There is no fallback functionality for specific browsers. This table shows how the field is displayed with and without formatting:
Before formatting | After formatting |
---|---|
For a document download, the raw data is of
type IPFDocumentI and displays as the name of the file uploaded: |
Set Field Display Format to
Text
Set Display Data Property to Name |
For a document upload, the raw data is of type IPFDocumentI and in this case, there is no data in the property, which results in the display being an empty/blank component. | Set Field Display Format to Button
Set Display Data Property to DocumentUpload where the DocumentUpload unbound property was
created in custom scripting and is set to Document Upload
During file upload, this changes to: After upload completes,
this changes to: Also after upload completes, the data of the property has been populated with the uploaded document (IPFDocumentI). |