From Josh Dayment & Ryan Mercer: Improved File Upload in Flow Screens

This Post was most recently updated on: 9/29/21

One of the common things I hear from users when uploading files in a Salesforce Flow is that they do not know if the file uploaded. This improved File Upload component adds this capability – plus a few other features – to the standard File Upload. Add this to any screen flow you wish to enable for upload.

Check out the new Version 1.3 improvements, courtesy of Ryan Mercer.

Here is a full list of features included with this component:

  1. Display the list of uploaded files and icons, providing visual confirmation;
  2. Create a link to preview the uploaded file (for internal users only);
  3. Specify the accepted file formats that can be uploaded;
  4. Upload multiple (or single) files simultaneously;
  5. Require users to upload at least one file before proceeding, and prompt them with a custom message if they do not;
  6. Bypass community sharing rules to allow community users to upload files to records to which they do not necessarily have access;
  7. Delete uploaded files immediately in the UI; and
  8. Outputs three text collections of the newly created files for use downstream in your flow:
    1. ContentDocument Ids
    2. ContentVersion Ids
    3. File Names


{!$Flow.InterviewGuid}StringNEW! ACTION REQUIRED: If you’re upgrading from a previous version of File Upload Improved, you will need to add this configuration to each component after upgrade.Unique identifier for this field. You can start by using {!$Flow.InterviewGuid}. If you have multiple of this component type in the same flow, you’ll have to prepend {!$Flow.InterviewGuid} with something else like ‘1’ or ‘2’ to make each component unique.If you only have ONE File Upload Improved component in your screen flow, you can use this:If you have MULTIPLE File Upload Improved components in your screen flow, you can use this:Though this field is not marked as required, admins should ALWAYS input a value here.
Accepted FormatsString (comma separated)The accepted file types. Enter a comma-separated list of the file extensions (such as .jpg) that the user can upload.
Allow Multiple FilesBooleanLets the user upload multiple files. *lightning-file-upload currently doesn’t support uploading multiple files at once on Android devices.
Bypass Community Sharing RulesBooleanThe default configuration will prevent community users from upLoading a file to a record that is not shared with them. To bypass and allow community users to upload a file to the record specified in the Related Record Id (regardless of if they have access to it), select TRUE. IMPORTANT – If true, the community users must have the ‘File Upload Improved’ permission set.
File Upload LabelTextThe text on the file upload button.
Related Record IdTextThe Id of the record to associate the files with.
RequiredBooleanRequire the user to upload at least one file.
Required Validation MessageTextThe validation message displayed if the user has not uploaded at least one file. The default message is ‘Upload at least one file.’
Uploaded File List LabelTextThe text on the list of files uploaded. You might find that you prefer to leave this blank as the UI is self explanatory.


Content Document IdsText CollectionThe Ids of the uploaded files. Store this value in a text collection variable.
Content Version IdsText CollectionThe Version Ids of the uploaded files. Store this value in a text collection variable.
Uploaded File NamesText CollectionThe names of the uploaded files. Store this value in a text collection variable.

The newly outputs can be accessed via manual assignment or automatically:


Version 1.4 9/29/21 (Enhancements)

(click here for Installation Troubleshooting)

Previous Versions

Version 1.3.1 8/23/21 (Enhancements)

Version 1.1.1 Unmanaged 5/31 bug fix

Version 1.1

Version 1.0

*to install in a Sandbox replace login with test in the url

View Source