web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

No record found.

News and Announcements icon
Community site session details

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

D365 New Fields In Map CustVendTrans and flowing it into CustTrans Or VendTrans from LedgerJournalTrans

(0) ShareShare
ReportReport
Posted on by 2,546

How can i add new fields in map CustVendTrans  and can flow it into  CustTrans Or VendTrans from LedgerJournalTrans.

I have already created a extension of class CustVendVoucher and want to use initCustVendTrans().

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    nmaenpaa Profile Picture
    101,166 Moderator on at

    You can't add new fields to the standard map.

    Please see this discussion for more info about workarounds: community.dynamics.com/.../281073

  • Verified answer
    Piyush Adhikari Profile Picture
    2,546 on at

    Yes it seems that the feature is missing :(

    I am using the code in following way

    [ExtensionOf(classStr(CustVendVoucher))]

    final class AcxCustVendVoucher_Extension

    {

       public void post(

           LedgerVoucher _ledgerPostingJournal,

           CustVendTrans _custVendTrans,

           NoYes _approval,

           UnknownNoYes _euroTriangulation,

           boolean _withHoldTaxType,

           boolean _useSubLedger)

       {

           LedgerJournalTrans  ledgerJournalTransLocal;

           VendTrans   vendTransUpdate;

           Common  commonLocal = common;

           next post(_ledgerPostingJournal, _custVendTrans, _approval, _euroTriangulation, _withHoldTaxType, _useSubLedger);

           if (commonLocal.TableId == tableNum(LedgerJournalTrans))

           {

               ledgerJournalTransLocal = commonLocal;

               if (_custVendTrans.tableid == tableNum(vendTrans))

               {

                   ttsbegin;

                   //*******NOT Recommended*********

                   //either update in vendTrans or custtrans

                   select firstonly1 vendTransUpdate

                       where vendTransUpdate.RecId == _custVendTrans.RecId;

                   vendTransUpdate.selectForUpdate(true);

                   vendTransUpdate.DocumentNum = ledgerJournalTransLocal.accountName();

                   vendTransUpdate.doUpdate();

                   ttscommit;

                   //*******Recommended*********

                   //or insert record with reference of VendTrans.RecId into a seperate table like AcxVendTrans

               }

           }

       }

    }

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

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Stars!

Congratulations to our 2025 Community Spotlights

Thanks to all of our 2025 Community Spotlight stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Joris dG Profile Picture

Joris dG 5

#2
Sagar Suman Profile Picture

Sagar Suman 2 Super User 2026 Season 1

#2
Alexey Lekanov Profile Picture

Alexey Lekanov 2

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans