How do you access a macro in the AOT macro node?
I have the following macro in the macro node of the AOT in AX 2012 #localmacro.printSettings classStr(SrsPrintDestinationSettings), xSession::systemSessionId() #endmacro How can I then access this in code? Basically i want to be able to pass certain print settings to the macro and then grab those settings using the macro as well.
Macros can only manage parameters that make sense to be writed on the source code. They are not intended to receive and manage objects as parameters. If you need so, you'll need to implement a regular method, as Jan B. Kjeldsen stated on their answer.
The use of macros is all explained here. Do not make it too complicated, if it is, you are better served using regular methods.
How to insert into a table field with value from a display method dependent of string
x++ cannot read registry entry
How do I get the caller Form's name in the Insert() of a table in AX 2012?
How to lookup into another table using EDT AX 2012
Set a Date Value to a Date Field in AX2012
Determine if a job is running in X++ code
Dynamics AX 2012 parsing Int32 to table field integer
Cancel Sales order packing slip through x++
Transferring open account records between customers
How to make sure that a form is only opened once?
Extend system menu in Dynamics AX 2012?
How to show selected items of certain table on the different table in Dynamics AX 2012?
AllowEdit doesn't work properly in Dynamics AX
AX 2012 how to set args record datasource in X++
Clients seem to be running old (buggy) code after XPO project import
Number sequence AX 2012