Hi,
I am unable to get the FullName,FirstName, LastName or YomiFullName of a SystemUser using LINQ query in plugin. All these have values in the SystemUserBase table.Below is the code
var createdList= from u1 in orgContext.SystemUserSet
where u1.Id == postAppt.CreatedBy.Id
select new
{
YomiFullName = u1.FullName,
FirstName = u1.FirstName,
LastName = u1.LastName,
InternalEMailAddress = u1.InternalEMailAddress
};
foreach (var cUser in createdList)
{
createdByUser = cUser.YomiFullName;
localContext.TracingService.Trace("cUser " + cUser.FullName+ " " + cUser.InternalEMailAddress + " " + cUser.LastName);
break;
}
Note : I am getting the value for InternalEMailAddress.
maybe the problem is with this line
YomiFullName = u1.FullName,
you are assigning to YomiFullName field, try to assign to FullName as
FullName = u1.FullName,
Hi,
I checked the tracelogs, the user has value for FullName, FirstName & LastName. Is there any other way to get User Fullname? Basically I need to get the Created by Name for an Appointment record
I would first make sure the user record has these values set. You could include the user record GUID in your trace line and copy the GUID and open that user record in the UI and see if the user has FN, LN and Full Name set.
Daivat Vartak (v-9d...
225
Super User 2025 Season 1
Muhammad Shahzad Sh...
106
Most Valuable Professional
Eugen Podkorytov
95