0

Is there a way to auto-populate the fields based on the lookup field while user is on the New record screen? Example, Let's say I have custom object called Project. I have a lookup field "Master project" that is a lookup on the same object. When a user tries to create a new record and selects a project in that master project field, it populates certain fields before the user saves the new record, based on the record in the lookup.

New Project ==> New Project Screen opens ==> User selects a record in a lookup field ==> auto populates certain fields ==> Users review/changes the data in auto-populated fields ==> Saves the new record which closes the New project Screen

I know I can use a flow to update those fields after a new record is created but I want to see if there is a way to update those fields while the record is being created.

4
  • The flow can update fields before the record is created: help.salesforce.com/s/…
    – identigral
    Feb 24 at 18:41
  • and you want the fields to populate on the screen as soon as the user supplies the lookup field? This requires overriding the New action with either VF or aura
    – cropredy
    Feb 24 at 23:28
  • @cropredy Pretty much. I have never worked with VF or aura so I'm not sure how I'd go about it. There's only a few folks who are asking for it so I'm not sure if it'll be worth the hassle if VF/Aura has a high learning curve
    – SWP
    Feb 26 at 1:40
  • Basically, you need to use client side (aura) or pseudo-client-side (VF) logic (Ajax) to respond to user actions that then does queries to populate other input fields. You could try using VF to override the New button but delegate the work to a screen flow where you can do all the work in declarative style. VF is legacy, aura is legacy but LWC at this time can't override New button
    – cropredy
    Feb 26 at 5:02

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy