Hi guys, Today we see how to copy or duplicate a record in same table in ax 2012 using X++.
We can use Table standard "DATA" method. Check below code. We can copy one buffer data to other buffer data.
we can use buf2Buf(fromTableName , toTableName) also.
here I am using Data method.
static void copyData(Args _args)
{
DAXChild daxChild,daxChild1;
;
select daxChild where daxChild.EmpId=='555';
daxChild1.data(daxChild);
daxChild1.insert();
}
Before Running the above Job.
Result:
Keep Daxing!!
No comments:
Post a Comment