Visual Workflow

Hidden Gems – Visual Workflow

I recently did a training on Visual Workflow for a group of users. I can’t tell you how many times that I come across items that I wasn’t aware of while doing training prep, and this time was no exception. What follows are 3 items for Visual Workflow and 1 for its redheaded stepchild–Process Builder. These are all items you can incorporate into many Visual Workflows to be more efficient, troubleshoot errors and test future actions. If you want to share any other lesser known Visual Workflow items please post in the comments. If Visual Workflow means nothing to you, I highly recommend going through this Trailhead from Salesforce to learn more about them.

Global Variables in Visual Workflow

Overview: Global Variables in Visual Workflow give you similar capabilities as you find in a standard formula field outside of Flow. If you were like me, you may have assumed that these didn’t exist in Flow at all. Go to any other type of area besides a formula in Flow and the only thing you see under System and Global Variables was $Flow only. Dive into a Flow formula and you can see much more. It’s just like you can from within a formula/validation rule, etc.

How you might use this: I formerly created a formula field on an object in Salesforce that told me the $User.Id so I could pull it into my Flow and know who initiated the Flow. Now you can create this within a flow itself by referencing it within a flow formula. Find it at System And Global Variables. Once created, the $User.Id can allow a decision to be made based on the User’s information, send them an email and much more.

Flow Resource System and Global Variable

Pre-Built Apex for Process Builder

Overview: Shane McLaughlin created these for anyone to reuse. Just deploy these to your Salesforce Org.  Warning: Use at your own risk as this has some powerful functionality (like deleting records).

How you might use this: First, to install this click here and then on the Deploy to Salesforce button (Thanks AndyintheCloud!). Make sure you have the Thanks setting for Work.com enabled or it will not deploy. Check out the list for everything this can do OR watch the video(s) at the github repo.

1. Delete Records
2. Re-run Lead Assignment Rules
3. Refresh a dashboard
4. Assign Permission Sets to Users
5. Give a Thanks Badge
6. Process Builder Debugging
7. Chatter Follow
8. Lock/Unlock records
9. “Manually” share records

 

Look Ma! No hands!! A field value was updated and

no more record in Salesforce!

Detailed Error Message Email

Overview: Get more information than what is included in the Fault emails that are soooo helpful on their own than those sent out by Salesforce. The email provides minimal identifying information and many times a very cryptic Error Message as well. The Knowledge Article for this does a pretty good job of detailing what to do here. Unfortunately this is only for Visual Workflow but, for the ability to have improved Process Builder, errors go vote this Idea up!

How you might use this: Be more informed and troubleshoot errors faster. Add more information to your error emails than you get with the default ones. Things like the record name, user name, the initiating record’s Id, which step it errored out in, etc. Don’t forget to connect all of your CLUD (Create, Lookup, Update and Delete) elements back to your Fault email element with a Fault connector!

Error message for flow
Error message for flow

My favorite gem is for last…and another Blog Post.  Stay tuned; it’s a good one!

Blog by Andy Davidson  Andy is a Certified Salesforce Admin
and a Senior Consultant at Cloud Co-Op, Living in Austin TX.

Cloud Co-Op and Andy are ready to show you the power

 of Visual Workflow for automating business processes

Hidden Gem Image: https://www.pexels.com/photo/wood-nature-forest-trees-4917/
Boom Image: https://pixabay.com/en/explosion-detonation-blast-burst-147909/

Share
This

Post a comment