“Impossible” Requests

A client once asked me if we could route end users to new Salesforce cases that were created via a screen flow.

At the time, I didn’t know of any screen flow elements that let us do that, so I said “It couldn’t be done.”

Disappointed to hear it wasn’t possible, the client half-heartedly said, “Ok I’ll guess we’ll just have to train our users then.”

As someone with a rebellious streak, when I hear “it can’t be done” I’m just so curious if its truly impossible that I have to find out!

Aware enough to realize I had used those limiting words myself – my rebel nature and natural curiosity kicked in.

Surely one person – somewhere – has figured this out?

Instead of doing nothing, I told the client I’d research if anyone had solved the problem before and maybe we could find a solution.

It turns out I learn the most about Salesforce when someone (even if its me) says something “can’t be done in Salesforce”.

One single Google search later, and I found a YouTube video showing exactly how to redirect users with a screen flow.

Later I also found this excellent Salesforce Help Article about the flow action we can build to achieve a redirect.

As an aside, it’s crazy to think how many things we don’t know about – perhaps even life changing information – are on the other end of the right Google search.

A fun thought experiment is asking yourself “What’s one Google search that changed the course of my life?”

Simple searches like “best vacation spots” or “fun events near me” can cascade into doing things you never realized existed!

Back to the story, with only 3 or 4 clicks the Help Article shows how we can create a Lightning Web Component with copy & pasted code.

This component is reusable in any screen flow, handles the redirect for you (so long as you provide the record ID), and does not require any Apex test classes to deploy. It can be moved to production “as is” and it works.

Inside the flow builder we use an action to get the LWC on the canvas, and when the flow runs the action is what causes the redirect – taking the end user to a newly created record or any other record that you choose.

I created a short YouTube video about the redirect Flow Action this week that goes in more detail than we will here.

If you ever need to redirect users in a Screen Flow in the future – remember a Google search can help you find it!

Ultimately, I was able to build this exact component for the client, and when he saw it in action he said it was perfect (one of my favorite things to hear from clients!). Woohoo!

So tell me, have you ever caught yourself (or anyone else) saying “it can’t be done in Salesforce” and then found a way to succeed? Let me know!

Have a great weekend,

Nick

Keep reading

See all posts →

Salesforce Saturdays

Join 1,036 Salesforce pros getting one 10-minute tip on Salesforce tech or career growth every Saturday.