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

Community site session details

Session Id :
Microsoft Dynamics AX (Archived)

Adding two new fields to LedgerTransVoucher

(0) ShareShare
ReportReport
Posted on by

Hi everyone,

I have  to add two new fields in the form of LedgerTransVoucher that display the AccountNum and Name of both customers and vendors based in the Voucher value. So i added two display methods that return correctly the two fields but the ctrl+G doesn't work with display methods. I have read some posts that suggest to create a syscomputed column in a view but in this case it doesn't work because the table of generalJournalEntry related to the form can't be linked to the two datasources CustTrans and VendTrans (that contain the accountNum) at the same time. i have tried to make it work but it isn't possible. 

So i have i want to create two new fields in GeneralJournalEntry (accountNum and name) to relate it to the form but i can't know where to insert the code that retrieves the data from custTrans, vendtrans and dirpartyTable( that contains Name field).  I need your help please.

Best regards

*This post is locked for comments

I have the same question (0)
  • Suggested answer
    Rustem Galiamov Profile Picture
    8,072 on at
    RE: Adding two new fields to LedgerTransVoucher

    Take a look at the LedgerVoucherObject class and new() method.

    You can fill the new fields there. But you should debug posting process first to be sure what all necessary data you can get.

  • Community Member Profile Picture
    on at
    RE: Adding two new fields to LedgerTransVoucher

    Ok Crispin, i 'm reading about batch job, i understand what it gives but the  object type of the menu item LedgerTransVoucher is the form. i can't modify it to call the batch job that should be created. Do you mean that if i create a new menu item that calls the batch job class it will retrive the data from cut/vendTrans to the new fields in ledgerJournalEntry?

    Regards;

  • Community Member Profile Picture
    on at
    RE: Adding two new fields to LedgerTransVoucher

    Hi Crispin,

    Can you explain more please? thank you,

    Best regards

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

Responsible AI policies

As AI tools become more common, we’re introducing a Responsible AI Use…

Mansi Soni – Community Spotlight

We are honored to recognize Mansi Soni as our August 2025 Community…

Congratulations to the July Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > 🔒一 Microsoft Dynamics AX (Archived)

#1
Syed Haris Shah Profile Picture

Syed Haris Shah 9

#2
Mea_ Profile Picture

Mea_ 4

#3
KP-31070522-0 Profile Picture

KP-31070522-0 3

Last 30 days Overall leaderboard

Featured topics

Product updates

Dynamics 365 release plans