+ Start a Discussion
vamsi krishna 106vamsi krishna 106 

We can’t execute the API because the parent record isn’t selected.

var recordId = cmp.get("v.recordId");
       var Fields = { ToAddress: {value: "to@to.com"}, 
                     ParentId	: {value: recordId}, 
                     HTMLBody: {value: "the text body", insertType: "cursor"} }
        var args = {actionName :"Case.Send_Email"};
            console.log('Available Fields are ', JSON.stringify(result));

                console.log('Action Field Log Errors are ',e.errors);
                console.error('Full error is ', JSON.stringify(e));

try to using the "quickActionAPI" and gettting the 

below error "We can’t execute the API because the parent record isn’t selected."
Calling the Quickaction from lightning component and it's not working. please let me if i am doing anything wrong..

Thanks in advance.Full Screen
Khan AnasKhan Anas (Salesforce Developers) 

Hi Vamsi,

Greetings to you!

Please refer to the below links with a similar discussion which might help you further with the above issue.




I hope it helps you.

Kindly 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. It will help to keep this community clean.

Thanks and Regards,
Khan Anas

Kumar BittuKumar Bittu

I am also facing the same error message "We can’t execute the API because the parent record isn’t selected."

Also not able to understand about - what needs to be add to pagelayout or published. As I have custom component button on component page that is avaialbe on lightning record page. 
Can somebody plz explain the proper way or solution for it.
Renzo VargasRenzo Vargas
The line 08 should not be commented and check the Page Layout Assignment
I am facing same issue. none of links provided above worked well to me.
Kevin 13Kevin 13
@Marcio_Fritsch were you able to find a solution to the problem? Thanks!