-
How to prepopulate EventWhoids in Salesforce lightning component?
I am trying to create a lightning component which uses e.force:recordCreate and prepopulates a list of ContactIds in the EventWhoIds field. However, the contact do not get prepopulated in the form.
console.log(component.get("v.contactIds"));
var contactRecords = component.get("v.contactIds");
console.log("contactRecords: " + contactRecords);var createEvent = $A.get("e.force:createRecord");
createEvent.setParams({
"entityApiName": "Event",
"defaultFieldValues": {
'WhatId' : component.get("v.recordId"),
'EventWhoIds' : contactRecords
}
});
createEvent.fire();-
This discussion was modified 5 years, 4 months ago by
Prachi.
-
This discussion was modified 5 years, 4 months ago by
Forcetalks.
-
This discussion was modified 5 years, 4 months ago by
Forcetalks.
-
This discussion was modified 5 years, 4 months ago by
Log In to reply.
Popular Salesforce Blogs

Maximizing your Marketing Potential in 2024
In today's digital landscape, the ability to effectively engage with customers across various channels is crucial for businesses striving to stay ahead of the competition.…

Making Financial Services Firms Thrive Amidst Challenges in 2024
A competitive market along with a challenging economic climate has made it tough for financial services companies to acquire new customers, and provide better customer…

Angular JS with Salesforce Remote Actions
Using Angular JS with Remote Actions Nowadays Angular JS is a great front end framework in order to manipulate DOM and do many more things…
Popular Salesforce Videos
What is Lead Assignment rule in Salesforce and How to create it?
This video explains Lead Assignment rules in depth in an interesting way and fun way. This video is divided into 4 parts: - What is…
How to Configure Lightning Sales Path Salesforce
In this video, Pratima provides a detailed demo on how to configure the Lightning Sales Path, the Lead path for Standard and custom objects, the…
Salesforce Consultant Certifications - Large Data and Transaction Volumes
As you already aware, expertise in Salesforce is in huge demand. The Salesforce Certifications are industry-recognized and are a proof of your skill/expertise in Salesforce.…