• Jordan Wight 7
  • NEWBIE
  • 0 Points
  • Member since 2020

  • Chatter
    Feed
  • 0
    Best Answers
  • 0
    Likes Received
  • 0
    Likes Given
  • 0
    Questions
  • 2
    Replies
As of Spring 20 release, we can again prepopulate field values using a URL - aka URL hacking (see release note here (https://releasenotes.docs.salesforce.com/en-us/spring20/release-notes/rn_general_lex_navigate_to_record_dfv.htm)).

I, for one, am so happy for this feature. However, there is one minor problem. When the URL is invoked, the new record modal pops up, and if the user chooses to Cancel, a blank page is displayed instead of returning to the page where the URL was called.

Below is the URL that I'm using. It is invoked with a custom list button located in a related list of an Opportunity.

/lightning/o/Case/new?defaultFieldValues=
AccountId={!Opportunity.AccountId},
Opportunity__c={!Opportunity.Id}

I've tried including a retunURL parameter - in different places in the URL. But no luck.
Hi,  wondered if anyone could help determine why my Return URL is not working on a custom button.
 
"/a0E/e?CF00N20000001ZdDo_lkid={!Opportunity.Id}&CF00N20000001ZdDo={!Opportunity.Name}&retURL=https://emea.salesforce.com/{!Opportunity.Id}"
 
The above related to a new custom object related to the opportunity, on saving I would like it to return back to the opportunity.   I have tried lots of different options, even sending it to an external website to see what happens, but everytime it just takes me to the saved new record.
 
Is this not possible to do with custom objects, same code "retURL" works on custom event buttons.
 
Thanks for any assistance