function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
Akhil KunaAkhil Kuna 

How can I set a Finish location for a flow in Lightning experience?

I'am using standard flow component.
NagendraNagendra (Salesforce Developers) 
Hi Akhil,

Set Flow Finish Behavior with a Flow URL:
By default, when a flow interview that uses screens finishes, a new interview for that flow begins, and the user is redirected to the first screen. If you want to redirect users to another page within Salesforce when they click Finish, use the retURL parameter in the flow URL.

Format:
To redirect users to a specific page in Salesforce after they click Finish:
1/flow/flowName?retURL=url
where url is a relative URL (the part of the URL that comes after https://yourInstance.salesforce.com/ or https://yourInstance.lightning.force.com/).

Now inorder to set the finish location you just have to replace above url with the relative URL. For redirecting you can redirect user to anywhere in the org but not external. Checkout here for more redirections.
https://developer.salesforce.com/docs/atlas.en-us.salesforce_vpm_guide.meta/salesforce_vpm_guide/vpm_url_set_retURL.htm

Example: This flow URL redirects users to Accounts home, which exists in both Lightning Experience and Salesforce Classic.
1/flow/myFlow?retUrl=001/o
Hope this helps.

Kindly mark this as solved if the information was helpful.

Thanks,
Nagendra

 
Vimarsh SaxenaVimarsh Saxena
Hi Folks,

How do I edit my flow URL? When I click on Edit, I can only edit the Name of the flow but not the URL.

Thanks!
Vimarsh Saxena
Satyadev Revanth Chilakamarri 14Satyadev Revanth Chilakamarri 14
@Vimarsh, Im in the same boat. Were you able to figure out where to edit flow url?
Thanks.
Vimarsh SaxenaVimarsh Saxena

Hi Satyadev,

No I couldn't add retURL parameter. I am using custom action to launch my flows right now and cannot navigate to the new record being generated.

The flow URL is an option when you use custom button or link. For my scenario, my flow creates a record in the end where I wish to navigate but this is only possible with a Visualforce Page I guess.

If you find any solution, please let me know.

Thanks!

IT Support EnessIT Support Eness
How about this: https://developer.salesforce.com/docs/atlas.en-us.lightning.meta/lightning/components_using_flow_onfinish.htm ?