I am trying to set the default of a people picker field to current user. I am able to accomplish this by using the typical code:
{
'@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
DisplayName:User().FullName,
Claims:"i:0#.f|membership|" & Lower(User().Email),
Department:"",
Email:User().Email,
JobTitle:"",
Picture:""
}
I want to be able to set the record so that in the event another user edits the form, the initial user who created the entry remains the same and doesn't change to the new user editing the form.
I tried the following in various ways but am getting an error in my 'IF" statement. Any help would be appreciated. Thanks!
If(EditForm1.Mode = FormMode.New,
{
'@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
DisplayName:User().FullName,
Claims:"i:0#.f|membership|" & Lower(User().Email),
Department:"",
Email:User().Email,
JobTitle:"",
Picture:""
},
Parent.Default)