Alfasith AX

Alfasith AX
اللَّهُمَّ انْفَعْنِي بِمَا عَلَّمْتَنِي، وَعَلِّمْنِي مَا يَنْفَعُنِي، وَزِدْنِي عِلْمًا

Saturday, May 24, 2014

To get current User name in Dynamic AX

Hi,

print xUserInfo::find().id;
   
print xUserInfo::find().name;
   
pause;

Note: if it print ADMIN nothing to worry, because it printing your exact id only. this will be Admin when you,  working on domain project / project in domain instance this will print current user perfectly.

Regards,

No comments:

Post a Comment

How find size of recordsortedlist in D365/AX 2012

Hi, This is the continuity of the previous article where we are now getting the size of recordsortedlist . if(recordsortedlist.len() >1) ...