I'm using the relatively new fields SystemCreatedBy and SystemModifiedBy, but I do not want to display the ID but the users-name instead - can it be linked directly to the user's table (which would be which?).
Thanks!
Sorry -I'm simply trying to display the values of these fields (like here) on a page; for the datetime-fields the display-value is fine, for the SystemCreatedBy/SystemModifiedBy (which are SID's) I want to display the corresponding user's full-name (as stored in table user).
For now I have this peace of code:
procedure GetFullName(userID: Guid): Text
var
UserInfo: Record User;
begin
if not UserInfo.Get(userID) then
exit('');
exit(UserInfo."Full Name");
end;
field("appSystemCreatedBy"; GetFullName(Rec.SystemCreatedBy))
{
ApplicationArea = All;
}
Can you please explain your requirement in bit detail.
If you access those fields in Front end. You will see a lookup of the user/team entity with name.
In the backend when you will retrieve these value in coding, you will get this value as EntityReference under which you can get 3 details.. 1. entityName 2. RecordId..3. Name.. based on the 3rd value you can identitfy the name.
If the 3rd value is empty in EntityReference. Then you need to make an extra service call to retrieve the desired data by using the RecordId and entity name.
Stay up to date on forum activity by subscribing. You can also customize your in-app and email Notification settings across all subscriptions.
André Arnaud de Cal... 291,240 Super User 2024 Season 2
Martin Dráb 230,149 Most Valuable Professional
nmaenpaa 101,156