Skip to main content

Notifications

Microsoft Dynamics AX (Archived)

insert the selected rows as a new record in ax 2009

Posted on by 770

If i click the button, the selected line value(record) in the Grid should be inserted as new record

If i click the button then selected line should be split as two record(Based on the Table numeric Field value(If that Field value = 5 means, after divided the first record that Field value = 3 and another one will be 2.

How to achieve this 2 solution....?

*This post is locked for comments

  • Bilal Issa Profile Picture
    Bilal Issa 4,370 on at
    RE: insert the selected rows as a new record in ax 2009

    Hi Mummad,

    in the click button you can use the code below and in the example I use ItemGroup

    ItemGroup newItemGroup;

    buf2buf(selectedItemGroup, newItemGroup) //  selectedItemGroup is form data source

    newItemGroup.GroupId = 'NewId';

    newItemGroup.insert();

  • MUHAMMAD HAARIS Profile Picture
    MUHAMMAD HAARIS 770 on at
    RE: insert the selected rows as a new record in ax 2009

    Hi Bilal,

    Duplicate record should be saved in same table only. the above two process done in same table.

    Can u expalin little bit more...?

     

    Regards,

    Muhammad Haaris.

  • Bilal Issa Profile Picture
    Bilal Issa 4,370 on at
    RE: insert the selected rows as a new record in ax 2009

    Hi ,

    you can use Buf2Buf(origRecord,NewRecord) , then change the field you want in the new record.

    Regards,

    Bilal

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

December Spotlight Star - Muhammad Affan

Congratulations to a top community star!

Community AMA December 12th

Join us as we continue to demystify the Dynamics 365 Contact Center

New! Quick response templatesâš¡

Save time with the new custom templates!

Leaderboard

#1
André Arnaud de Calavon Profile Picture

André Arnaud de Cal... 291,219 Super User 2024 Season 2

#2
Martin Dráb Profile Picture

Martin Dráb 230,056 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans