How to include custom fields in the process of confirming registration lines on the InventTransRegister Form?

My requirement is to add two custom fields in the grid of Registration Lines Tab in the InventTransRegister Form, and to insert the values of those fields to the grid of Transactions Tab once the “Confirm Registration” button is clicked.

The standard process here is the records from the registration lines are inserted to transactions tab after confirm registration is clicked.

Here is the path for the form: Production control > Production orders > All production orders > Inventory tab > Update registrations.

Highlighted in red are the custom fields:


The Registration lines grid datasource is TmpInventTransWMS and the Transactions grid datasource is InventTrans. Therefore, I placed the custom fields on those two tables.

However, I can’t seem to find how the TmpInventTransWMS temp table is being populated in this table, and how the InventTrans table is being populated. So I can’t figure out where to include the insertion / updating of the custom field values.

I’ve tried following the call stack, but I can’t seem to find a way to include a code for the custom fields.


Are there any events inside the form that I can use to insert / update a transaction record instead if that is a possible solution?

I also tried looking for solutions and found one possible solution, however it’s applicable on AX 2012 and unfortunately, I can’t do overlayering here in D365. But here’s a link if anyone would like to take a look:

Thank you!