Thursday, May 7, 2015

Dynamics NAV 2013 - Mass Archive Purchase Orders

Function to Mass Archive all Purchase Orders

MassArchivePurchDoc()

//PurchHdr.SETFILTER(PurchHdr."Document Date",'01/08/14');
IF PurchHdr.FIND('-') THEN BEGIN
REPEAT

    StorePurchDocument(PurchHdr,FALSE);
UNTIL PurchHdr.NEXT = 0;
MESSAGE ('All Purchase Orders Archived');
END;

No comments:

Post a Comment