Hi,
I'm trying to save some documentation time by creating a script that generates technical documentation from AX. The idea is to generate a word document which describes all CUS layer changed objects (subtitles for fields, methods, properties, ...).
This works fine with the TreeNode traversal, except for the properties on table/class level.
I only seem to be able to get a list of all properties of the table, yet I am only interested in the not-default / user changed properties (= the ones that are highlighted in bold in the properties window).
Here's a POC of the traversal job:
static void TstGetProperties(Args _args)
{
TreeNode table, tableCUP, tableSubCUP;
TreeNodeIterator tableIterator;
TreeNodeTraverser nodeTraverser;
str tableProp, tableCUPprop;
#AOT
;
table = TreeNode::findNode(#TablesPath + "\\" + "CustTable");
tableCUP = table.getNodeInLayer(UtilEntryLevel::cus);
nodeTraverser = new TreeNodeTraverser(tableCUP);
table = nodeTraverser.next();
while (table)
{
info(strFmt("%1, %2", nodeTraverser.infologPrefix(), nodeTraverser.currentNode().AOTgetProperties()));
table = nodeTraverser.next();
}
}
I would prefer to avoid reading XPO's from source control and 'scraping' those.
Any help would be greatly appreciated,
thanks,
Gabriël