ALAppExtensions icon indicating copy to clipboard operation
ALAppExtensions copied to clipboard

[var Request] Codeunit 80 "Sales-Post" - ArchiveUnpostedOrder

Open aobsgit opened this issue 5 years ago • 3 comments

Could you please change SalesHader parameter to "var"? As we are updating Sales Header in Archive Management codeunit, we need this to be a var parameter. Thank you

OLD CODE

procedure ArchiveUnpostedOrder(SalesHeader: Record "Sales Header")
var
    SalesLine: Record "Sales Line";
    ArchiveManagement: Codeunit ArchiveManagement;
    IsHandled: Boolean;
begin
.
.
.

NEW CODE

procedure ArchiveUnpostedOrder(var SalesHeader: Record "Sales Header")
var
    SalesLine: Record "Sales Line";
    ArchiveManagement: Codeunit ArchiveManagement;
    IsHandled: Boolean;
begin
.
.
.

aobsgit avatar Sep 22 '21 10:09 aobsgit

Call of ArchiveUnpostedOrder located after we do Modify of Sales Header in procedure CheckAndUpdate. What is the reason of this update in your case, can you think about different design for your purpose?

AlexanderYakunin avatar Sep 22 '21 11:09 AlexanderYakunin

Thank you for such a fast reply. OK, we will rethink this. Thank you for now.

aobsgit avatar Sep 22 '21 12:09 aobsgit

Thanks for reporting this. We agree, and we’ll publish a fix asap, either in an update for the current version or in the next major release. Please do not reply to this, as we do not monitor closed issues. If you have follow-up questions or requests, please create a new issue where you reference this one.

JesperSchulz avatar Oct 07 '21 08:10 JesperSchulz