File Attachment
The file attachment field is for uploading and storing a file. If the uploaded file is an image, the file attachment field can show a preview of the image.
How to Create
Features
Field Label
Grid Appearance
Block Association
Image and Thumbnail
File Control
File Import
Validation
Audit History
View Only
File Access
Field parts
The File Attachment Field has eleven different output formats:
Full Field - This output format returns the file name of the stored file (e.g. image.jpg).
Download
URL - If the File Attachment Field is set to allow public access to the file, this output format returns the
URL where the stored file is found. If the Field is not set to allow public access, it returns a path to the image which attempts to force the browser to download the file.
Filename - This output format returns the file name of the stored file (same as Full Field output).
File Size - This output format returns the size of the file in bytes.
File
URL - If the File Attachment Field is set to allow public access to the file, this output format returns the
URL where the stored file is found. If the Field is not set to allow public access, it returns a path to the image, but does not attempt to force the browser to download the file.
Height - If the uploaded file is an image, this output format returns the height of the image in pixels.
Image - If the uploaded file is an image, this output format returns an
HTML tag which will show the stored image. If the uploaded file is not an image, it will not return anything.
Mime Type - This output format returns the Internet Media Type of the uploaded file (e.g. image/jpg or text/html).
Thumbnail - If the uploaded file is an image, this output format returns an
HTML tag which will show the stored image. If the uploaded file is not an image, it will not return anything.
Thumbnail
URL - If the uploaded file is an image and the File Attachment is set to allow public access, this output format returns the
URL where the stored thumbnail is found. If the uploaded file is an image, but the Field is not set to allow public access, it will return a path to the thumbnail. If the uploaded file is not an image, it will not return anything.
Width - If the uploaded file is an image, this output format returns the width of the image in pixels.
Uploading a file in WorkXpress is easy. In add or edit mode, the File Attachment Field appears as a box with a “Browse” button next to it. Click the box or the button to launch a file upload dialog box, navigate to the file, and click Save. When the Form that the File Attachment Field is on is saved, the file will be uploaded.
Copying File Attachment Values in Actions
To copy a File Attachment's Value in an Action, set the “Full Field” Part of the field you want to set to the “WX Stored Value” of the field you are reading, and the files will copy in the background correctly.
Saving a File Attachment from a URL
If you have the URL to a file on the internet, you can use an action to push that URL into a File Attachment field, and that file will be downloaded and saved in the File Attachment Field.