The AL language version 14 introduces a new "this" keyword for self-reference on all objects in Dynamics 365 Business Central. This keyword allows codeunits to pass a reference to "this" as an argument to another method and improves readability by signaling that a referenced symbol is a member on the object itself. The new "this" keyword works on every AL object, but codeunits and interfaces are where it can be used the most. Examples of usage include passing "this" as a value to a method, referencing an enum value using the "this" syntax, and using "this" in page objects. Overall, this addition adds an "object-oriented" aspect to the AL language.
Login now to access my digest by 365.Training