0

I'm new to salesforce, Is there any way to use a Custom Label in URL

https://developer--uat.lightning.force.com/lightning/r/Report/00O0w000000ZLryEAG/view?fv0={!Service_Provider__c.Name}

Instead of https://developer--uat.lightning.force.com/lightning/r/Report

how to use custom labels here ..! Thanks in Advance.

  • It's likely that you want to use Custom Metadata for this instead of Custom Labels. As per documentation Custom labels are custom text values that can be translated into any language that Salesforce supports.. Are you intending to translate the name of the provider in other languages? – Arthlete Jul 1 '20 at 5:15
0

Custom labels cannot be used in Custom buttons or links. However, they can be used in URL type fields set via default values (formula editor), Workflow field updates or triggers.

0

You cannot reference label in Custom Button or Link. In your custom button, you actually do not need to specify the domain name. So below works:

/lightning/r/Report/00O0w000000ZLryEAG/view?fv0={!Service_Provider__c.Name}

What you need to make as variable is the report ID. You can use Custom Setting (Hierarchy type) so that you can reference it in the Custom Button/Link.

Let say your custom setting name is Report_ID__c and the field is MyReport__c, then:

/lightning/r/Report/{!$Setup.Report_ID__c.MyReport__c}/view?fv0={!Service_Provider__c.Name}

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.