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
Tyler FergusonTyler Ferguson 

How to create an Auto launched flow

I'm new to flows and looking for some help/guidance.

I created a new custom object "Budgets" for our Search Managers to track spend budgets from various mediums (Google, Bing, Facebook, etc..). What I am looking to do is update the status of the old budget when a new one is created given it meets the right criteria.

Ex: 
      Google Budget = $5,000
      Campaign Type = Search
      Budget Status = Active

When a new budget for a Google search campaign is entered into the object for $7,000 and is marked active. I need to flow to find the old budget and update the status to "Expired". 
Deepali KulshresthaDeepali Kulshrestha
Hi Tyler,

Greetings to you!

There are many scenarios where we need to create/update records. If there is complex business logic where we need to create and update records based on certain conditions, then generally, Developer goes with Apex Triggers and starts writing hundreds lines of code. Obviously, that is not a good practice.
Developers forgot the powers of lightning flows where we can build complex business logic with some clicks and drags. So, as part of this article; I am going 
to explain how can we make good use of lightning flow and Process builder.

Please go through the below link.
https://www.sfdcpanther.com/create-update-records-using-process-builder-and-auto-launched-lightning-flow/

I hope you find the above solution helpful. If it does, please mark as Best Answer to help others too.

Thanks and Regards,
Deepali Kulshrestha
www.kdeepali.com