function readOnly(count){ }
Starting November 20, the site will be set to read-only. On December 4, 2023,
forum discussions will move to the Trailblazer Community.
+ Start a Discussion
AbAb 

Populating data from parent record when a button is clicked on child object.

Hello,

there is Activities history on a custom object.
This has a standard button send email. But this button is not customizable.
Hence, i want to create a Visualforce page + Apex to overvide this custombutton.

My usecase:
There is a record of a custom object which have activity history. One of the field in them is Email__c, i wantt that when user clicks on the button it should automatically populate the email id of the current parent.

I am not concerned with populatig data, i will later see how to email it.

thank you for suggestion
Best Answer chosen by Ab
Amit Chaudhary 8Amit Chaudhary 8
If you are using Apex class and VF page then you can pass ID or parant record in URL and make a query in constructor and get the all values

All Answers

Pun!5h3rPun!5h3r
Hello, I hope the VF page will contain child record??
Amit Chaudhary 8Amit Chaudhary 8
If you are using Apex class and VF page then you can pass ID or parant record in URL and make a query in constructor and get the all values
This was selected as the best answer