0

I'm trying to create a 'New' button using the Link button with URL. This is for my custom object that I need to pre-fill when the New button is clicked. For example, I have CustomObjectA that has a related list view for CustomObjectB

enter image description here When I click the button New, it should show the form with the default values. I wrote the syntax as below:

/lightning/o/CustomObjectB__c/new?defaultFieldValues=Field1__c={!CustomObjectA__c.Field2__c}

the syntax has no error, but when I clicked the button, it's not populated by default. What should be the proper URL then?

1 Answer 1

0

I used this URL button and it is working. Is your case different with some other text field ? Try checking parameters and API name of field. Hope this helps. PS - Do check limitations of url buttons before implementation. Screenhots: Button Setting

Test Value and button

Default Populated Value

1
  • Hi KKumar, thank you for this. I tried a text type field and it works but when I tried populating lookup fields. it's not pre-populating. Does this supposed to work on lookup fields also?
    – Mae
    Mar 23 at 1:42

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .