X++ in AX7: Forms implementing interface
Views (902)
|
|
Forms can now implement interfaces.
public class MyForm extends FormRun implements SysPackable
{
}
|
This is pretty cool, because:
- The compiler will validate that the interface is correctly implemented.
- No longer a need to use reflection, like hasFormMethod(), to determine if it is safe to call the method.
-
No longer a need to downcast to object to invoke the methods. Now cast to the interface:
var sysPackable = myFormRun as SysPackable; if (sysPackable) { sysPackable.pack(); }
THIS POST APPLIES TO MICROSOFT DYNAMICS AX7 TECHNICAL PREVIEW; IS PROVIDED AS-IS AND CONFERS NO RIGHTS.

Like
Report
*This post is locked for comments