How to populate Person column in SharePoint List in Canvas Apps

 Hello Everyone!!! Welcome to Anything & Everything in Tech. In this blog I will guide you how to create SharePoint list record which has Person column. I have a list called User Report which has a person column named User


On each and every operation of the user a log record is created from the canvas apps. We all know using patch request we can create a row in the list but there comes the problem how to pass the person value in it??.

Well the rescue steps are here by, use the below format in your patch request to populate the person column

 User: {

            '@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",

            Department: "",

            Claims: "i:0#.f|membership|" & Lower(User().Email),

            DisplayName: User().FullName,

            Email: User().Email,

            JobTitle: "",

            Picture: ""

        }

here, the parameters are very straight forward such as Department, Claims, Display Name and Email, Job Title etc. User() is the currently logged in user in the canvas app. The final patch statement looks as shown below.


Hope this blog helped you. Please subscribe/follow for more insights.

Comments

Popular posts from this blog

How to display AM/PM for a Date field in Canvas Apps

{When a HTTP Request is received trigger Power Automate Additional Options}