+ Start a Discussion
Yasemin Kahraman 4Yasemin Kahraman 4 

Hi, l have been working on "Platform App Builder Certification Maintenance (Winter '21) Get Hands-on With Flow Before-Save Trigger When Certain Record Changes are Made" part and it gives me 
" Whoops, looks like there was a problem. Please try again." error message many times although l tried on new and old sandbox.  Both didnt work. Can somebody help me about it ? thanks in advance. it is important to keep my certification. 
User-added imageUser-added image
Best Answer chosen by Yasemin Kahraman 4
AbhishekAbhishek (Salesforce Developers) 
Your query is answered here,


If you still face the issue reach below,



So that our trailhead support engineers will look into it and get back to you.

Let me know if it helps you and close your query by marking it as solved so that it can help others in the future.

​​​​​​​Salesforce Support.
Shavi DabgotraShavi Dabgotra 

Hi Everyone!

I want a list of account using Lightning-datatable. But it is not displaying the list of accounts.

    <lightning-card title="t">
        <template if:true={accList}>
    <template if:true={error}>


import { LightningElement ,api, wire, track} from 'lwc';
import getAccountList from '@salesforce/apex/AccountHelper.getAccountList';
export default class Test extends LightningElement {
    @track columns = [{
            label: 'Account name',
            fieldName: 'Name',
            type: 'text',
            sortable: true
            label: 'Type',
            fieldName: 'Type',
            type: 'text',
            sortable: true
    @track error;
    @track accList ;
    }) {
        if (data) {
            this.accList = data;
        } else if (error) {
            this.error = error;

Apex Class: 

public with sharing class AccountHelper {
    public static List<Account> getAccountList() {
        return [SELECT Id, Name, Type, Rating,
                Phone, Website, AnnualRevenue
            FROM Account LIMIT 10];


<?xml version="1.0" encoding="UTF-8"?>
<LightningComponentBundle xmlns="http://soap.sforce.com/2006/04/metadata">


User-added image

I want the list of accounts.

Thank you in Advance!

Best Answer chosen by Shavi Dabgotra
Hii Shavi Dabgotra
Just Copy Paste The Following Code
    <lightning-card title='Data-Table'>
    <div style="height: 300px;">
import { LightningElement,wire } from 'lwc';
import getAccountList from '@salesforce/apex/AccountHelper.getAccountList';
const columns = [{ label: 'Account name',fieldName: 'Name',type: 'text',sortable: true},
                 {label: 'Type',fieldName: 'Type',type: 'text',sortable: true}];
export default class Test extends LightningElement {
    data = [];
    columns = columns;
    records = '';

        this.wiredActivities = value;
        const { data, error } = value;
        let dataEditing = JSON.parse(JSON.stringify(data));
        this.records = dataEditing.length;
        this.data = dataEditing;
    }else if(error){
        this.error = error;
Please Mark It As Best Answer If it Helps
Thank you
Ranjith DevRanjith Dev 
Hi Team,

I have a lightning Component that used the access="global". Salesforce has suggested please remove the access="global" in all lightning components.
User-added image
but when I remove the access="global", the package got not Upload it showing an error message.
User-added image
any suggestion that would be helpful for me.

Thank you.
Ranjith M
Best Answer chosen by Ranjith Dev
SwethaSwetha (Salesforce Developers) 
HI Ranjith,
The error is probably related to the scenario explained in https://salesforce.stackexchange.com/questions/307758/component-is-from-a-managed-package-and-must-be-marked-access-global-on-sfd

If you are releasing a component as part of a package, then you definitely want your component to be accessible outside of your org, for which you would need to mark it with a global access.

See related: https://salesforce.stackexchange.com/questions/219001/lightning-component-in-this-managed-package-must-be-marked-access-global

If this information helps, please mark the answer as best.Thank you
Developer BaseDeveloper Base 

could anyone explain what are those so called Application Programming Interfaces? And why do we have so many of them? We have Streaming API, SOAP API, Metadata API and so many more.

Are APIs some sort of collections of classes and methods that can be used for a certain purpose?

And why is there so many of them when only one would be enough, containing all the methods?
Best Answer chosen by Developer Base
ANUTEJANUTEJ (Salesforce Developers) 
Hi there,

>> https://focusonforce.com/integration-and-data-loading/an-introduction-to-salesforce-apis/#:~:text=API%20stands%20for%20Application%20Program,a%20simple%20and%20secure%20manner. 

As stated in the above link "Salesforce provides programmatic access to your organization’s information using simple, powerful, and secure application programming interfaces[API's]."

There are many API's depending on the functionality we want to perform we choose the API and extend the functionality as per the requirement, below are list of API's that are provided by Salesforce:

REST API - Access objects in your organization using REST.
SOAP API - Integrate your organization’s data with other applications using SOAP.
Tooling API - Build custom development tools for Force.com applications. Coming soon!
Chatter REST API - Access Chatter feeds and social data such as users, groups, followers, and files using REST.
Bulk API - Load or delete large numbers of records.
Metadata API - Manage customizations in your org and build tools that manage the metadata model (not the data, itself).
Streaming API - Provide a stream of data reflecting data changes in your organization.
Apex REST API - Build your own REST API in Apex. This API exposes Apex classes as RESTful Web services.
Apex SOAP API - Create custom SOAP Web services in Apex. This API exposes Apex classes as SOAP Web services.
Data.com API - Data.com provides 100% complete, high quality data, updated in real-time in the cloud, and with comprehensive coverage worldwide.

>> https://help.salesforce.com/articleView?id=sf.integrate_what_is_api.htm&type=5

The above link gives an explanation of when to use which API along with the list of API's.

Let me know if it helps you and close your query by marking it as solved so that it can help others in the future.  

Cristian WhiteCristian White 

Hi, how can I cover these remaining lines for this class? I'm struggling to understand why it is not covering all.. This is my class and coverage, I have 66% until now.

User-added image
This is my method from the test class which covers 66%.


static testMethod void linkTest() {

       	SVMXC__Service_Request__c sr = new SVMXC__Service_Request__c();
        sr.SVMXC__Status__c = 'Closed';
        sr.SVMXC__Priority__c = 'Medium';
        sr.Number_of_Open_Admin_Tasks__c = 2;
        sr.SVMXC__Type__c = 'Complaint CCM';
        insert sr;
    	List<SVMXC__Service_Request__c> listSr = [Select Id, SVMXC__Status__c, Name from SVMXC__Service_Request__c where Id=: sr.Id ];
    	ApexPages.StandardSetController setCtr = new ApexPages.StandardSetController(listSr);
    	setCtr.setSelected(new SVMXC__Service_Request__c[]{sr});
        MassUpdateSimpleControllerServiceRequest controller = new MassUpdateSimpleControllerServiceRequest(setCtr);
		// verify following exceptions will not cause exception
Best Answer chosen by Cristian White
static testMethod void massUpdate() {
        Account acc = new Account();
        acc.Name = 'ABC Labs';
        insert acc;
        List<Account> accLst = new List<Account>{acc};
            String value = 'This is my test desciption';
            new MassUpdater(accLst, Account.Description, value).massUpdate();
            //ToDo assert ApexPages.Message success message
            //System.assertEquals('Updated '+accLst.size()+ ' Records', new MassUpdater(accLst, Account.Description, value).massUpdate().getSummary());
            System.assertEquals(value, [SELECT Description FROM Account WHERE Id = :acc.Id].Description);
            new MassUpdater(accLst, Account.Name, '').massUpdate();
            //ToDo assert ApexPages.Message
            //System.assertEquals('Updated '+accLst.size()+ ' Records', new MassUpdater(accLst, Account.Description, '').massUpdate().getSummary());
            System.assertNotEquals('', [SELECT Name FROM Account WHERE Id = :acc.Id].Name);

Connie W 5Connie W 5 
my requirement is to create a report and track service appointmnet in field service.
Best Answer chosen by Connie W 5
VinayVinay (Salesforce Developers) 
Hi Connie,

Unfortunately, this feature is currently unavailable.  Kindly review below Idea link and vote for this feature.


If you are looking for service reports check below reference.


Developer BaseDeveloper Base 
Hey, I am studying for developer II cert and I ran into a peculiar thing.

my test class does NOT trigger mixed DML error, although I am inserting setup and non-setup objects. Why not? My code:
public class UpdateAccountNameTest {
    public static void test1(){
        Profile prfl = [Select Id, Name from Profile where name ='System Administrator'];
        Account acc = new Account();
        acc.Name = 'test';
        insert acc;
        Custom_Object1__c a = new Custom_Object1__c();
        a.Name = 'testAccount';
        insert a;
        User usr2 = new User();
        usr2.LastName = 'setup1';
        usr2.Username = 'test1@test123.net';
        usr2.Email = 'tes1t@test123.net';
        usr2.Alias = 'Test1';
        usr2.CommunityNickname = 'Test1';
        usr2.TimeZoneSidKey = 'Europe/Prague';
        usr2.LocaleSidKey = 'cs_CZ';
        usr2.EmailEncodingKey = 'UTF-8';
        usr2.ProfileId = prfl.Id;
        usr2.LanguageLocaleKey = 'en_US';
        usr2.IsActive = true;
        insert usr2;     

Best Answer chosen by Developer Base
Developer BaseDeveloper Base
So for some reason when creating a User record, if I do not create record with UserRoleId field, it wont trigger Mixed DML Error. That is the reason.
Jonathan Wolff 7Jonathan Wolff 7 
Hi, I'd like to build a chatter component that displays the title and author of the last 5 messages only. Can you give me a code example how to do it?
Best Answer chosen by Jonathan Wolff 7
AnudeepAnudeep (Salesforce Developers) 
Hi Jonathan, 

I believe this is possible and you'd need to target FeedComment as per the diagram shown on the below page 


Below is the link to the Developers Guide on the Objects stored under each Feed Object for example Account_Feed etc


You can look at the sample chatter component here as well 

Let me know if this helps, if it does, please mark this answer as best so that others facing the same issue will find this information useful. Thank you

Shavi DabgotraShavi Dabgotra 

I have created a drop down menu in lightning web component. But, I want a pop up will appear on click of a menu item. 
I tried this for pop up, But it is not working. On click of a "Rename " Menu item . A pop up will be shown.


    <div class="slds-p-around_medium lgc-bg">
        <lightning-card title="Drop Down">
            <lightning-button-menu alternative-text="Show menu" variant="border-filled" onselect={handleOnselect}>
                <lightning-menu-item value="openinsharepoint" label="Open in SharePoint" prefix-icon-name="utility:new_window"
                <lightning-menu-item value="rename" label="Rename" prefix-icon-name="utility:edit">
                    <template if:true={ready}>
                        <section role="dialog" tabindex="-1" class="slds-modal slds-fade-in-open slds-modal_small"
                            aria-labelledby="modal-heading-01" aria-modal="true" aria-hidden="true"
                            <div class="slds-modal__container">
                                <!-- Modal/Popup Box LWC header here -->
                                <header class="slds-modal__header">
                                    <button class="slds-button slds-button_icon slds-modal__close slds-button_icon-inverse" title="Close" onclick={closeModal}>
                                        <lightning-icon icon-name="utility:close"
                                            size="small" ></lightning-icon>
                                        <span class="slds-assistive-text">Close</span>
                                    <h2 id="modal-heading-01" class="slds-text-heading_medium slds-hyphenate">Rename LWC Setup.docx</h2>
                                <!-- Modal/Popup Box LWC body starts here -->
                                <div class="slds-modal__content slds-p-around_medium" id="modal-content-id-1">
                                    <lightning-input type="text" name="folder_name" label="Rename" placeholder="Enter new item name">
                                <!-- Modal/Popup Box LWC footer starts here -->
                                <footer class="slds-modal__footer">
                                    <button class="slds-button slds-button_neutral" onclick={closeModal} title="Cancel">Cancel</button>
                                    <button class="slds-button slds-button_brand" onclick={submitDetails} title="Create">Create</button>
                        <div class="slds-backdrop slds-backdrop_open"></div>
                <lightning-menu-item value="download" label="Download" prefix-icon-name="utility:download">
                <div class="slds-has-divider_top-space" role="separator">
                    <lightning-menu-item value="delete" label="Delet" prefix-icon-name="utility:close"></lightning-menu-item>


import { LightningElement, track } from 'lwc';
export default class ButtonMenuOnselect extends LightningElement {
    @track selectedItemValue;
    @track ready;
    handleOnselect(event) {
        this.selectedItemValue = event.detail.value;
        if(this.selectedItemValue == "rename")
        this.ready = true;


Best Answer chosen by Shavi Dabgotra
Hii Shavi Dabgotra
Just Copy Paste  The following code
  <div class="slds-p-around_medium lgc-bg">
    {selectedItemValue} {ready}
    <lightning-card title="Drop Down">
        alternative-text="Show menu"
          label="Open in SharePoint"
        <div class="slds-has-divider_top-space" role="separator">
      <template if:true={ready}>
        <div class="slds-box slds-theme_shade">
          <div class="slds-modal slds-fade-in-open slds-backdrop">
            <div class="slds-modal__container">
              <!--HEADER Section-->

              <div class="slds-modal__header">
                  alternative-text="Close this window"
                <h2>Rename LWC Setup.docx</h2>
              <!---Body Section-->
              <div class="slds-modal__content slds-p-around_medium">
                  placeholder="Enter new item name"
              <!--Footer Section-->
              <div class="slds-modal__footer">
                  class="slds-button slds-button_neutral"
                  class="slds-button slds-button_brand"



 @track selectedItemValue;
    ready = true;
    handleOnselect(event) {
        this.selectedItemValue = event.detail.value;
        if(this.selectedItemValue == 'rename')
        this.ready = true;
        this.ready = false;

Please Mark It As Best Answer If it Helps Thank you
Admin User 10568Admin User 10568 

Hoping someone could help me out.

I have the following apex class: 

public class PriceListAscending{
private String sortOrder = 'REPRO__Project_Name__c';
public list<REPRO__Project__c> getEvents() {
    list<REPRO__Project__c> results = Database.query(
        ' SELECT REPRO__Project_Name__c, REPRO__Properties__r.REPRO__Property__c, REPRO__Properties__r.REPRO__City__c, REPRO__Properties__r.Property_Level__c, REPRO__Properties__r.Price_List_Property_Name__c, REPRO__Properties__r.REPRO__Type__c,REPRO__Properties__r.REPRO__Bdr__c,REPRO__Properties__r.REPRO__Bth__c,REPRO__Properties__r.REPRO__Study__c,REPRO__Properties__r.REPRO__Internal_Size__c,REPRO__Properties__r.REPRO__External_Size__c, REPRO__Properties_r.REPRO__Car_c, REPRO__Properties__r.REPRO__List_Price__c, REPRO__Properties__r.REPRO__Status_c ' + 
        ' FROM REPRO__Project__c'  + 
        ' ORDER BY ' + sortOrder + ' ASC '
    return results;

There is no error displayed in the editor. 

When I try to call the fields from a pageblocktable for my visual page, I get the following error: Invalid field Property_Level__c for SObject REPRO__Project__c

Here is an example of the call: 

<apex:pageBlockTable value="{!Events}" var="e" align="center" cellpadding="2" border="4"  style=" font-weight: bold; text-align: center" >
  <apex:column value="{!e.Property_Level__c}" style="padding: 10px;order-bottom: 1px solid #ddd;border: 1px solid black; text-align: center; " />

Any help would be greatly appreciated.
Best Answer chosen by Admin User 10568
AnudeepAnudeep (Salesforce Developers) 
This is a child to parent SOQL. Can you please check if you have a field named Property_Level__c on the object REPRO__Properties__c

See example below

Traverse multiple level upwards

There is a custom lookup field on contact object called Best Friend and there is a field called likes ice cream. Write a query to retrieve the custom field
SELECT Id, Best_Friend__r.Likes_Ice_Cream__c FROM contact

Here we’re traversing a custom lookup field Best_Friend__c on the contact object. Notice how the “__c” changes to a “__r” when traversing that field!