Share Your Experience With Others

New Features in Salesforce & solution of some problem

  • Use Lightning Experience look and feel in Visualforce pages
    Set lightningStylesheets="true" in the <apex:page> tag.
  • Get the Developer Name for Record Types More Easily
    Now you can use the following methods to get the developer name.
    Schema.DescribeSObjectResult.getRecordTypeInfosByDeveloperName()
    Schema.RecordTypeInfo.getDeveloperName()
  • If Auth.SessionManagement.getCurrentSession() failing in test class or in deployment then:
    write it into if condition like this:
    if(!Test.isRunningTest()){
    Map<String,String> sesstionMap=Auth.SessionManagement.getCurrentSession();
    }
  • Understand How to Troubleshoot Processes and Flows
    Access debug logs from the Logs tab in the Developer Console. 
    Or from Setup, enter Debug Logs in the Quick Find box. 
    In the level, set Workflow to Finer.
    Use these debug event types to monitor flow usage against per-transaction governor limits.

    FLOW_START_INTERVIEW_LIMIT_USAGE—Includes the number used by the transaction upon starting the flow interview but before executing flow elements. Also includes the per-transaction limit.
    FLOW_ELEMENT_LIMIT_USAGE—Includes the number used by the flow element, the total count used by the transaction after executing the element, and the per-transaction limit.
    FLOW_BULK_ELEMENT_LIMIT_USAGE—Includes the number used by the element executed in bulk, the total count used by the transaction after executing the element, and the per-transaction limit.

  • New URL Format for Lightning Experience and the Salesforce Mobile App
  • Here are some examples of the new format.
    Object Home page:
    Previous format: https://<lightning.domain.com>/one/one.app/#/sObject/Account/home
    New format: https://<lightning.domain.com>/lightning/o/Account/home
  • Record page:
    Previous format: https://<lightning.domain.com>/one/one.app#/sObject/006R000000245p1IAA/view
    New format: https://<lightning.domain.com>/lightning/r/Opportunity/006R000000245p1IAA/view
  • Existing URLs that use /one/one.app, like ones you’ve saved or have in emails, will continue to work.
  • When they’re executed, they’re translated into the new format.
  • You can also use the new URLs with the Lightning Console JavaScript API.
  • Custom or installed Lightning components that parse a URL may break or behave differently after this change, especially components with logic that relies on window.location or the aura:locationChange event.
  • If you have query string parameters appended to /one/one.app such as /one/one.app?myparam1=xyz&amp;myparam2=abc, they’re rewritten as /lightning?0.myparam1=xyz&amp;0.myparam2=abc.
  • Quickly Identify the Salesforce Theme That Users See in JavaScript
    UITheme.getUITheme() returns a string that indicates the current user’s interface theme.
  • function isLightningDesktop() {
    return UITheme.getUITheme === "Theme4d";
    }
  • Use these variables to identify the CSS used to render Salesforce web pages to a user.
  • Theme1—Obsolete Salesforce theme
    Theme2—Salesforce Classic 2005 user interface theme
    Theme3—Salesforce Classic 2010 user interface theme
    Theme4d—Modern Lightning Experience Salesforce theme
    Theme4t—Salesforce mobile app theme
    Theme4u—Lightning Console theme
    PortalDefault—Salesforce Customer Portal theme
    Webstore—Salesforce AppExchange theme

Leave a comment