General X++ Development
How do I override `modified()` on a form control using an extension?
How do I override modified() on a form control using an extension?
1 answer
Write an answerUse Chain of Command on the control method when that method is available to wrap.
[ExtensionOf(formControlStr(MyForm, MyControl))]
final class MyForm_MyControl_Extension
{
public boolean modified()
{
boolean ret = next modified();
// Your logic.
return ret;
}
}Do not copy standard control logic into your extension. Let the standard method run through next and add only what you need.
Know the solution?
Sign in to contribute an answer and build your community reputation.
Sign in to answer