I have a tracker tied to a SharePoint List that assigns tasks to individuals in our office and utilizes an Office365Users connection to search for their account. I am able to search for them in a drop down ('Assigned to_DataCard2' and 'DataCardValue9') using
Office365Users.SearchUser({searchTerm:DataCardValue9.SearchText,top:10})
as the Items property. My problem is that I would like the drop down to default to the current logged in user but am receiving an argument type error. I have tried
If(EditForm1.Mode=FormMode.Edit,ThisItem.'Assigned to', Office365Users.SearchUser({searchTerm:User().Email}))
for the Default property of 'Assigned to_DataCard2' and
If(EditForm1.Mode=FormMode.Edit,Parent.Default, Office365Users.SearchUser({searchTerm:User().Email}))
for the DefaultSelectedItems of 'DataCardValue9' but both return an invalid argument type error saying they expected a record. What seems to strange to me is that if I replace the if statement which just one of the true or false statements (eg hisItem.'Assigned to' or Office365Users.SearchUser({searchTerm:User().Email})) it works without error. Thanks for any help you can give me.