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
ManvithaManvitha 

Cloning Records - related list clone

Hi All ,

Need help on one scenario: If the opportunity is cloned all the related list /records will be cloned .But in my scenario even after cloning,  on the old opportunity a few new tasks should be automatically created .& I want these tasks to be shown on the cloned opportunity as well in the activity  .Can someone confirm is that possible and if yes how can we achive this .

NOTE;on  old oppo and new or cloned oppo , 3 task will automatially create simulateously 
Thanks in Advance 

 

VinayVinay (Salesforce Developers) 
Hi Manvitha,

You can use Clone with Related Button on pagelayout by using standard button.

https://merfantz.com/blog/how-to-clone-the-record-with-related-list-in-salesforce-by-using-standard-button/

Else you can use flow to clone a record with Its related list records,  Check below example for same.

https://salesforcetime.com/2021/12/25/using-flow-to-clone-a-record-with-its-related-records/
https://salesforce-flowsome.com/use-case-clone-any-objects-with-related-lists-with-flow/

Please mark as Best Answer if above information was helpful.

Thanks,
Gabriel Hall 4Gabriel Hall 4

To accomplish your goal of automatically creating new tasks on the original opportunity and displaying them in the cloned opportunity's activity section, you can follow these steps:

Create a Process Builder or Workflow Rule: Use a Process Builder or Workflow Rule to trigger the creation of new tasks when an opportunity is cloned.
Define the Task Creation Criteria: Set the criteria for when the tasks should be created. This could be based on a specific field value or any other relevant conditions that determine when the tasks should be generated.
Configure Task Creation Actions: Within the Process Builder or Workflow Rule, configure the actions to create the new tasks. You can specify the task details, such as subject, due date, assigned user, and any other required fields.
Specify Related Opportunity: When creating the tasks, make sure to set the "WhatId" field of the tasks to the cloned opportunity's record Id. This will associate the tasks with the cloned opportunity.
Test and Validate: Save your configuration and perform thorough testing to ensure that when an opportunity is cloned, the specified tasks are automatically created on the original opportunity and are visible in the cloned opportunity's activity section.
By following these steps, you should be able to achieve your desired outcome of automatically creating tasks on the original opportunity and displaying them in the cloned opportunity's activity section.
Please note that the specific steps and options may vary depending on your Salesforce instance and version. It's recommended to consult your Salesforce administrator or refer to Salesforce documentation for detailed instructions based on your specific environment.

I hope this solution helps you in achieving your goal. If you have any further questions or need additional assistance, please feel free to ask.

Best regards,
https://www.mybkexperience.onl/