From Tamar Erlich: No Dynamic Forms? No Problem, Use Flow!

Dynamic Forms are the modern way to display record detail information to the user. They enable better control and new functionalities for record pages:
1. Show or hide sections based on criteria
2. Multiple column layouts
3. Separate sections in different tabs

The initial implementation of Dynamic Forms is available for Custom Object via App Builder. There’s also a new Dynamic Forms for Flow entering Beta in Summer ’21 that can be accessed in Screen Builder. But right now, you can’t use the Dynamic Forms that you find in App Builder on standard objects like Account and Contact.

No problem! Flow is here! You can used a flow screen to replace the record detail component on a standard record page and take advantage of the new layout features and dynamic functionality.

These two videos show 1) all the features you can leverage for a standard object and 2) how to build it in Screen Builder

A closer look at the construction of the flow screen:

Some options and ideas for use are:

  1. Use multiple flows with different layouts, and show or hide them on the page based on user or record criteria
  2. Separate layout sections on tabs on the record, using multiple flows
  3. Mix and match flow components on the page, arrange them using the new flow sections component, and take advantage of the new automatic fields in flow

Resources:
Dynamic Forms
The Record Detail Component
Dual List Box Component
Summer ’21 flow preview

Multiselect Magic: Manage Multiselect Picklists with Flow

Flow has never been good at managing multiselect picklist fields. Over the years, many intrepid flowhanites have provided assistance. Here, we provide an installable Flow Action that leverages last year’s new support for generic types to provide a nice and simple new way to solve problems that use these fields.

Use this new Manage Multiselect Field action to easily do these things:

  1. Select an additional value for a multiselect picklist field
  2. Deselect a selected value from a multiselect picklist field
  3. Check for the presence of a particular value in the set of selected values
  4. Given a specific record, obtain both the full set of available values and the currently selected values in the form of a List of Strings that can be used downstream in your flow with tools like QuickChoice.

Inputs

objectApiNameStringName of the object where your field is
fieldApiNameStringName of the multiselect picklist field you’re manipulating
operationStringSupported values are CheckForValue, ReturnStringCollection, AddValue, and RemoveValue
targetValueStringUse to specify a value to add or remove, or to check for whether a value is selected.
saveAutomaticallyBooleanIf set to true, will save any changes made by the action immediately. Note that this will commit any open transactions in the flow
curRecordRecordthe actual record you’re examining or changing

Outputs

availableValuesListList<String>
selectedValuesListList<String>
selectedValuesSemicolonStringString (this is the ‘native’ way that these fields store data)
targetPresentBoolean Returns a value if action is set to

Install

Version 1.0.4 4/7/24 Production Sandbox. Bug fix.

Old Versions

Version Unmanaged 5/16/21

Installation note: This package currently creates a multiselect picklist field called ‘Fruit__c’ on the Account object to provide something to run tests on. If that’s a problem, you can install this action without the test class by simply grabbing the main action code here and pasting it into a New Class in Developer Console.

Source

source

Developer Note: New Wiki Home Page for Flow Screen Component Development

There’s now a home page in the wiki for Flow Screen Component development:

Note that the wiki pages allow guest edits, and we really want to see people adding content to the wiki! So if you spot a good resource for developing Flow Screen Components, click the Edit Article button and add a link. It will go into a review queue so you needn’t worry that you’ll mess things up.

Hayes Davis – Building Custom Property Editors

Hayes Davis, Co-founder of GradientWorks, has posted a great walkthrough on how to utilize CPEs to help admins get more out of Invoked Actions and Screen Components in Flow.

Check it out!

https://www.gradient.works/blog/custom-property-editors-salesforce-flow

From Josh Dayment – Flow iFrame Lightning Web Component

The flow IFrame Lightning Web Component gives an admin the ability to display a website/web page inside of a Flow Screen Component. iFrames can be tricky and they have their pros and cons and in some cases are depreciated by some websites however if you have a use case they can be great. When would you want to use it in a flow? A few ideas I have run into have been things like displaying a Salesforce File via a flow screen or showing data that is in an external system that is not available via a direct integration via external services or some other type of API but a user needs to see the data. Possibilities are endless last year I embedded a virtual career fair inside of an Experience Site that did not have a direct integration with Salesforce allowing us to present data and actions from the Experience Site while also displaying conversations and navigation of the Career Fair.

Gotchas. There are always Gotchas! In order for this to work you will need to add the domain of the site to your trusted sites in your org. The site also needs to allow for iFraming as well. iFrames come with their own inherent security risk so be careful what information you are passing through the iFrame.

I know you are all saying thank you for my rambling of how I have used this and the Gotchas can you just show us how it works already! Let’s take a look

The component has three input variables.

Property LabelData TypeDescription
iFrame HeightText StringThe height in pixels of your iFrame
iFrame WidthText StringThe width in pixels of your iFrame
URLText StringURL of the site you wish to display in your flow

In my example below I am going to take a file I upload in my first screen create a public url for it and display it via Flow iFrame (to learn more about creating a Content Delivery aka public url for files check out this post from Narender Singh)

Screen 1 user is uploading a new file via fileUploadImproved

Next I am looping the contentDocumentIds (which is only one but I need it as a single text variable to create my Content Delivery)

On my final screen I am displaying the file to the user via Flow iFrame.

Now that I’ve bored you with the technical stuff check it out in real time.

Installation

v1.0.1 – 1/19/23 Production Sandbox added frameborder property

Old Versions

Version 1.0 Unmanaged – 5/13/21

View Source

source

From Tamar Erlich: GetRecordTypeInfoByObject Now Returns Default Record Type Info

Tamar has upgraded this useful action to also output information about the default record type ID and Name.

Check it out

Josh Dayment released Version 1.1 of File Upload Improved

This version includes two asks from the community. It includes the ability to restrict to only allow a single file for upload and also to set the accepted file formats check it out below.

There is now a new property for Accepted Formats this is a Comma Separated String Variable of accepted file formats for upload for example .pdf,.sxls,.jpg. If left null it will default to accept all file formats.

Also added was a property to control single or multiple file uploads. Allow Multiple Files is a boolean property that when set to True allows for multiple file uploads but when set to False will only allow for a single file upload. (The default is false)

Full Details and Download

April 2021 Community Flowcast Video

Much like last month’s ‘Flowcast’ – I highlight a bunch of components, articles, and actions featured here on UnofficialSF – check it out in the link below!

The description in the video has links to each of the articles mentioned – enjoy!

More Great New Sources for Flow Videos

I’m very impressed by the amount of great video content that’s getting published about Flow! Just in the last month or two, some vloggers have appeared, seemingly out of nowhere but with deep Salesforce knowledge and great video production chops.

Salesforce Break

Salesforce Break is publishing Summer 21 videos and created a monster 1 hour session on Flow with Terry’s Tidbits:

SFDC Craftsmanship

SFDC Craftmanship has an unmistakable look and is running a series right now on Flow solutions. Special props for using Unofficialsf’s beloved ‘Bangers’ font!

Adam Foyston

Adam started posting videos about Flow a month ago. I don’t know where Adam cut his vlogging teeth, but he’s bringin’ ALL of the video production goodness.

Salesforce Geek

Shubham has built up thousands of subscribers and covers more than just Flow. Lately he’s been creating a lot of flow scenarios and enhancement reviews.

Check it out!

Datatable now supports Picklist field edits

A huge thanks to Guillaume Davies and Jerry Poon from Accenture in Sydney Australia for sharing their solution for supporting Picklist Field editing in the Datatable component.

Download the latest version (3.2.0) of Datatable to take advantage of this new and often requested feature. Currently, all available picklist values will be made available for selection when editing the fields. I’m working on fututure enhancements to support picklist value restrictions based on one RecordType per table and to provide an option to include –None– as an available selection.