Create Code extension from AOT in D365FO -Microsoft Dynamics Finance and operations

 
Code Extension : 


posted by : Hariharasudan Kandaswamy


In case you missed this, Microsoft recently added one more option in Visual Studio to create an extension 'class' of any object (not as an object extension but an extension class to add code/new method).

Navigate to 'Application explorer' (aka AOT) and find your object, right click on this and you will find an option to 'Create code extension', if you select this, it will create a class with all syntax you need to create an extension of that object (i.e. final keyword, add 'ExtensionOf' at the top).



This action will create a class with the name 'ObjectName_Model_Extention' in your project with the below syntax,



This is super quick to create an extension call for any applicable object. (Yeah you can not create an extension on an EDT using this option ;) )

posted by : Hariharasudan Kandaswamy

Comments

Popular posts from this blog

Create a Tile in a D365FO Workspace with X++ - Microsoft Dynamics Finance and operations

X++ Code to fetch GST, SGST, IGST Sales amounts in D365FO -Indian GST calculation logic

Disable editing of specific financial dimensions on form -Microsoft Dynamics Finance and operations(D365FO)