Wednesday 17 December 2014

AX 2012 Job to check whether the EDT has Help Text.

static void listEDTWithoutHelpText(Args _args)
{
    #TreeNodeSysNodeType
    TreeNode              edtNode   = TreeNode::findNode("Data Dictionary\\Extended Data Types");
    TreeNodeIterator      ir        = edtNode.AOTiterator();
    TreeNode              childNode;
    str                   label;
    ;
    if (ir)
    {
        childNode = ir.next();
        while (childnode)
        {
            label = childNode.AOTgetProperty("label");
            if (label && !childNode.AOTgetProperty("extends")
                && (!strStartsWith(label, "@SYS")         // Modify this stuff yourself!
                    && !strStartsWith(label, "@SYP")      // Modify
                    && !strStartsWith(label, "@ESP"))     // Modify
                && !childNode.AOTgetProperty("HelpText"))
            {
               info(strfmt("EDT :%1, %2", childNode.AOTname(), childNode.AOTgetProperty("label")));
            }

            childNode = ir.next();
        }
    }
}

No comments:

Post a Comment

Calculate ledger balance by dimension set in X++ in AX2012/Dynamics 365 FO

There are a variety of ways users can view balances in the general ledger. Some of the most common options are: 1. Trial balance 2. Financia...