Skip to main content

Notifications

Announcements

No record found.

Microsoft Dynamics NAV (Archived)

Posted Approval Entry -G/L Entry

Posted on by Microsoft Employee

Hello,

 Is technically/Customizing possible to link the Posted Approval Entry table with the G/L Entry to Get fields Entry No. and Document No. in to Posted Approval Entry table.

Thank you and Regards,

Eri

*This post is locked for comments

  • Community Member Profile Picture
    Community Member Microsoft Employee on at
    RE: Posted Approval Entry -G/L Entry

    Thank you Alexander for your reply.

    Can you please advise on how do I populate the Document No. in G/L Entry  in to Posted Approval Entry table.

    MoveApprvalEntryToPosted(VAR ApprovalEntry : Record "Approval Entry";ToTableId : Integer;ToNo : Code[20])
    WITH ApprovalEntry DO BEGIN
    IF FIND('-') THEN
    REPEAT
    PostedApprvlEntry.INIT;
    PostedApprvlEntry.TRANSFERFIELDS(ApprovalEntry);
    PostedApprvlEntry."Table ID" := ToTableId;
    PostedApprvlEntry."Document No." := ToNo;
    PostedApprvlEntry."Document No. 2":=GLEntry."Document No."

    PostedApprvlEntry.INSERT;
    UNTIL NEXT = 0;
    ApprovalCommentLine.SETRANGE("Table ID","Table ID");
    ApprovalCommentLine.SETRANGE("Document Type","Document Type");
    ApprovalCommentLine.SETRANGE("Document No.","Document No.");
    IF ApprovalCommentLine.FIND('-') THEN
    REPEAT
    PostedApprovalCommentLine.INIT;
    PostedApprovalCommentLine.TRANSFERFIELDS(ApprovalCommentLine);
    PostedApprovalCommentLine."Entry No." := 0;
    PostedApprovalCommentLine."Table ID" := ToTableId;
    PostedApprovalCommentLine."Document No." := ToNo;
    PostedApprovalCommentLine.INSERT(TRUE);
    UNTIL ApprovalCommentLine.NEXT = 0;

    Regards,

    Aron

  • Suggested answer
    Alexander Ermakov Profile Picture
    Alexander Ermakov 28,094 on at
    RE: Posted Approval Entry -G/L Entry

    The relation between those would be on-to-many, meaning that one posted approval entry might be related to numerous G/L entries. I think it is possible, by adding a field "Posted Approval Entry No." in the G/L Entry table and generate respective logic to het that filled with correct Approval Entry No.

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!

Top 10 leaders for November!

Congratulations to our November super stars!

Tips for Writing Effective Suggested Answers

Best practices for providing successful forum answers ✍️

Leaderboard

#1
André Arnaud de Calavon Profile Picture

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

#2
Martin Dráb Profile Picture

Martin Dráb 230,235 Most Valuable Professional

#3
nmaenpaa Profile Picture

nmaenpaa 101,156

Leaderboard

Featured topics

Product updates

Dynamics 365 release plans