Site icon Microsoft Business Applications

Automatically create parm methods on AxBC classes in one line of code!



See More : http://www.alexondax.com/2014/07/howto-automatically-create-parm-methods.html

When you get this best practice error:

“The Table.Field does not have a corresponding parm-method on the AxBC-class”

You can save yourself time and automatically add the methods with this line in a job:

AxGenerateAxBCClass::newTableId(tableNum(WMSPickingRoute)).run();

Now whenever you run code that creates code, you should know what you’re doing.  Also, this won’t create the set methods, but I think that’s a bug on Microsoft’s part because part of the code appears to be there, but not used at all.  Look at `\Classes\AxGenerateAxBCClass\createInterfaceMethods` and see the variable `setMethodName` is not used.

Exit mobile version