This post is machine-translated. The original post in german language can be found here.

Create a list of favorites from current user

static void listFavoritesOfCurrentUser(Args _args)
{
    TreeNode treeNode;
    TreeNodeIterator iterator;
    TreeNode newTreeNode;
    int level;
    #AOT
    void loopChilds(TreeNode _treeNode)
    {
        level++;
        while(_treeNode)
        {
            info(strRep("    ", level-1) + any2str(SysLabel::labelId2String2(_treeNode.AOTname(), Global::currentUserLanguage())));
            loopChilds(_treeNode.AOTfirstChild());
            level--;
            _treeNode = _treeNode.AOTnextSibling();
        }
    }

    treeNode = infolog.userNode();
    iterator = treeNode.AOTiterator();
    treeNode = iterator.next();
    if (treeNode)
    {
        treeNode = treeNode.AOTfirstChild();
        if (treeNode)
        {
            setPrefix(treeNode.AOTname());
            loopChilds(treeNode.AOTfirstChild());
        }
    }
}
These post applies to following version:
Dynamics AX 2012

 
 

 

 
 
 
Posts of the actual month
November 2024
MoTuWeThFrSaSu
 123
45678910
11121314151617
18192021222324
252627282930 
 
© 2006-2024 Heinz Schweda | Imprint | Contact | German version | Mobile version
In order to provide you with better service, this site uses cookies. By continuing to browse the site, you are agreeing to our use of cookies.