Uploading Files through Screen Flow is a bit tricky. We can’t use ‘Create Record’ element like we can for creating other records. And then we can’t even make the file upload mandatory like we can make other fields mandatory in Screen Flow.
This is a question that was asked by one of our Mastering Salesforce Flows course participants and since the solution is not very straight forward, we thought of documenting the whole solution in a step-by-step guide format and share with everyone.
Here’s the business requirement
- Create a Flow to create a record with Attachments (Files)
- Make the file upload mandatory
- If the user does not upload the file, then delete the record that was created
And here is the Flow design. Step-by-step with screenshots.
Introducing Mastering Salesforce Flows Training Course
Liked this post? We are now offering a complete self-paced, video-based training course on Mastering Salesforce Flows. The course comes with downloadable step-by-step PDF guides, unlimited access, free upgrades, area to ask questions, free preview & 100% money back guarantee. For more details, please click here.
Need Help with Flows?
Need advice on Flows? I also offer advisory & consulting services on Salesforce Flows. So, whether you want to create new Flows or migrate existing automations (Workflow Rules, Process Builder, Triggers) to Flows, I can help you analyze, design, plan & review. To initiate a discussion, please submit the contact form here stating your requirement or book a 30-minute free discovery call at this URL.
References & Useful URLs
- Help Article – Flow Screen Input Component: File Upload (5 mins) – https://help.salesforce.com/s/articleView?id=sf.flow_ref_elements_screencmp_fileupload.htm&type=5