Dear Friends,
Can anyone suggest where to write the x++ code for the below scenario.
I have added a field in the table "LedgerJournalTrans" by name "Branch" which holds the Branch segment value of the LedgerDimension of DefaultDimension.
Now I know the logic to update the field but my doubt is that where should I write the x++ code to update this field every time a process is run.
should I write in insert() method or update() method or in both, or is there any other way?
Regards
Martin.A
*This post is locked for comments
Hey Martin Arul,
I can see some misunderstanding of the process here. LedgerJournalTrans is a journal line, so it won't be created after posting, it's a document that is posted by AX. As the result of posting you will get ledger transactions.
Let's back to my original question.
What should trigger population of new field ?
How do you create LedgerJournalTrans ?
Do you need ledgerDimension to be populated if you will change value in new field ?
Dear Crispin John Augustine,
I shall try in here. Thanks for the reply.
Regards
Martin.A
Dear Ievgen Miroshnikov,
For example, when we post a ledger journal, records will be created in the table "LedgerJournalTrans". This table contains a field called "LedgerDimension" and while inserting the record the value for the field "LedgerDimension" will also be inserted. Now from the value of this "LedgerDimension" field I will extract the "Branch" segment value and write in a field called "BranchCode" which I created, in the same table "LedgerJournalTrans".
I asked for this scenario as to where I can write the code.
Regards
Martin.A
Hi Martin Arul,
What process are you talking about ? Could you please elaborate your question and add some details ?
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,240 Super User 2024 Season 2
Martin Dráb 230,149 Most Valuable Professional
nmaenpaa 101,156