Today , I will be sharing a small code snippet which can be used to get worker which is attached with the current system user.
Here is the code snippet.
UserId currentUserId;
Name workerName;
currentUserId = curUserId();
if (currentUserId)
{
workerName = HcmWorker::findByPerson(DirPersonuser::find(currentUserId).PersonParty).name();
}
Note : curUserId() is system based method which can be used to get current user which is logged in right now.
Subscribe to:
Post Comments (Atom)
Custom Business events Part 3 - (Activate custom business event) in D365 F&O
In this blog we will discuss about the steps to activate a custom business in D365 F&O. As we know that business event catalog does not...
-
Today, I will share another part of connecting azure blob storage with Dynamics 365 for finance and operations series. This part will be abo...
-
Today I will be discussing about how to create batch job through x++. Before going in code lets discuss what are batch jobs. Batch job : ...
-
Today, I will share another part of connecting azure blob storage with Dynamics 365 for finance and operations series. This part will be abo...
No comments:
Post a Comment
Note: only a member of this blog may post a comment.