Thursday, May 21, 2009

How many time user logged on to AX at the time (for 3 tier structure)

You can find the user logging count by using SysUsersOnline class as below.

container con1,con2;
;
con1 = conpeek(SysUsersOnline::getAllOnlineUserInfo(), 1);

for(counter1 = 1; counter1 <= conlen(con1); counter1++)
{
con2 = conpeek(con1, counter1);

if (conpeek(con2, 2) == curuserid())
{
countUser++;
}
}


No comments:

How to identify the user that was used to change an object from AOT in AX2012

Get the object name for which we need to track these (user and date&time) information's. Login to SQL Server Management Studio an...