While in AX2009 does not have registerOverrideMethod. Previously it was commonly used practice overriding form controls methods using following patern:
Let's assume example form CustInvoiceJournal Init (add following two lines to the end of init):
element.controlMethodOverload(true);
element.controlMethodOverloadObject(new CustInvoiceJournalCtrlOverload(this));
In CustInvoiceJournalCtrlOverload class all control overrides are in following pattern
controlName_methodName. Example CustInvoiceJour_InvoiceAccount_Modified
whole CustInvoiceJournalCtrlOverload class blueprint
class CustInvoiceJournalCtrlOverload
{
FormRun element;
}
void CustInvoiceJour_InvoiceAccount_Modified ()
{
info("test");
}
And this works like a charm. Except if a control name which I want to override is very long for example groupInterCompany_InterCompanyCompanyId. If I try to create method groupInterCompany_InterCompanyCompanyId_modified I am getting compiler error "Name is too long. Truncate name to groupInterCompany_InterCompanyCompanyId_." Does somebody have a clue how to overcome this issue?
*This post is locked for comments
I have the same question (0)