locked
Copy a record in a workflow? RRS feed

  • Question

  • CRM2016

    I have two custom entities, Transet and Transactions

    Transets  is a parent to Transactions. Is it possible in a workflow to create a copy record of the transet and associated records in transactions.

    Ie duplicate the transset record and transaction records within the transset and transactions entities

    The reason for this is transsets holds a banking record header of supplier payments, and trasnasctions hold the actual banking data for each supplier. When the record has been processed, the status is set as de-activated. Sometimes the customers have the requirement to duplicate the exact records and have requested that they can just copy them rather than re-enter the data


    Dont ask me .. i dont know

    Wednesday, April 13, 2016 10:05 AM

All replies

  • You will need some code to achieve this. The key aspect is to iterate through each transaction record to copy it. There are several approaches you could use. I'd go for one of:

    1. A Custom Workflow Activity to do all the work of copying the transactions - it would take input of the old and new transet records, and create the new transaction records
    2. A plugin on the transet record. You could add a self-join relationship on the transet entity, so that a new record has a reference to the record from which it is copied. The plugin could read this, and create new transaction records

    Microsoft CRM MVP - http://mscrmuk.blogspot.com/ http://www.excitation.co.uk

    Thursday, April 14, 2016 7:37 AM
    Moderator
  • Hi Pete,

    This would require development skills to copy parent as well as child records. If you have more than one entities and scenarios where you need to have the copy feature, you could have a look at this add-on.

    http://inogic.com/product/productivity-pack/click-2-clone-microsoft-dynamics-crm-records

    This will also you clone any entity and its related records without any development required.

    HTH

    Sam


    Dynamics CRM MVP | Inogic | http://www.inogic.com/blog | news at inogic dot com
    If this post answers your question, please click "Mark As Answer" on the post and "Mark as Helpful"

    Friday, April 15, 2016 4:44 AM
  • I faced a similar issue in the past and found the Record Clone Solution which Perform the same. And there is also an option to exclude certain fields from getting cloned.   Below are some basic features : Can Clone records from Workflows Ability to clone System entities as well as Custom and their related child entities Ability to Clone multiple records too (making X Clones of a single record in a click) Link- www.work365apps.com/record-clone Hope this Helps :)
    Friday, December 8, 2017 12:29 PM