Posting Sales Order with temporary record

ElmqvistElmqvist Member Posts: 2
Hello.

In Navision 3.70B I have a temporary table of Sales Headers that I would like to post in a batch using CU 81. I'm using the vSalesHead (temporary) to update the lines on the actual order SalesHead.

I'm a bit unsure of how CODEUNIT.RUN handles the record that you try to post, so my question is if I could remove the SalesHead.GET and instead send vSalesHead to CU 81. Would Navision try to post the temporary copy of the order or the actual sales order in table 36 and 37.

IF vSalesHead.FIND('-') THEN
REPEAT
UpdateShipQtyOnSO(vSalesHead);
SalesHead.GET(vSalesHead."Document Type",vSalesHead."No.");
CODEUNIT.RUN(CODEUNIT::"Sales-Post + Print",SalesHead);
UNTIL vSalesHead.NEXT = 0;

Best regards.
Peter
Sign In or Register to comment.