web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Patch Sharepoint "Pers...
Power Apps
Unanswered

Patch Sharepoint "Person or Group" column with Office365 list from Combo Box

(0) ShareShare
ReportReport
Posted on by
I am trying to Patch a Sharepoint "Person or Group" column with Office365 Users from Combo Box.
 
The Combo Box "Items" code is as follows and works to search Users from the Office 365 connector:
Filter(Office365Users.SearchUserV2(
{
searchTerm:Trim(Self.SearchText),
isSearchTermRequired:false
}
).value,AccountEnabled=Not("#EXT" in UserPrincipalName
))
 
DefaultSelectedItems =
It is blank
 
My Patch function is as follows but does not work. Specifically the Combo box is causing the error:
Patch('Front Desk Messages',
Defaults('Front Desk Messages'),
{
Title:txt_ContactName.Text,
'OSARC Contact':cmb_OSARC.Selected.DisplayName,
'Contact Date':Date_Contact.SelectedDate,
'Contact Time':txt_ContactTime.Text,
'Contact Phone No':txt_ContactNumber.Text,
'Contact Email':txt_ContactEmail.Text,
'Contact Message':txt_ContactMessage.Text
}
);
Reset(txt_ContactName);
Reset(cmb_OSARC);
Reset(Date_Contact);
Reset(txt_ContactTime);
Reset(txt_ContactNumber);
Reset(txt_ContactEmail);
Reset(txt_ContactMessage)
 
I also attached another patch function that I have tried.  Nothing seems to work. 
Capture3.JPG
Capture2.JPG
Capture4.JPG
Categories:
I have the same question (0)
  • v-xiaochen-msft Profile Picture
    Microsoft Employee on at

    Hi @jchammons ,

     

    Please try this

    vxiaochenmsft_0-1707362933851.png

     

    Best Regards,

    Wearsky

  • jchammons Profile Picture
    on at

    No luck with anything I do. See attached and below code. 


    Patch('Front Desk Messages',
        Defaults('Front Desk Messages'),
        {
             Title:txt_ContactName.Text,
                     'OSARC Contact':
                {
                Claims:"i:0#.f|membership|" &  Lower(cmb_OSARC.Selected.Mail),
                Department: "",
                DisplayName: cmb_OSARC.Selected.DisplayName,
                Email: cmb_OSARC.Selected.Mail,
                JobTitle: "",
                Picture: ""
                },
            'Contact Date':Date_Contact.SelectedDate,
            'Contact Time':txt_ContactTime.Text,
            'Contact Phone No':txt_ContactNumber.Text,
            'Contact Email':txt_ContactEmail.Text,
            'Contact Message':txt_ContactMessage.Text
        }
    );


            Reset(txt_ContactName);
            Reset(cmb_OSARC);
            Reset(Date_Contact);
            Reset(txt_ContactTime);
            Reset(txt_ContactNumber);
            Reset(txt_ContactEmail);
            Reset(txt_ContactMessage)
    Capture5.JPG
  • jchammons Profile Picture
    on at

    Figured it out. For some reason, nothing likes the this part of the patch. Seems to not recognize the ".Mail" part.

    Email: cmb_OSARC.Selected.Mail

     

    Also I turned it into a "TABLE". It patches the Sharepoint Column and also my PowerAutomate works as well. The PowerAutomate sends an email to the person selected in the Combo Box.

     

    Patch('Front Desk Messages',

        Defaults('Front Desk Messages'),

        {

            Title:txt_ContactName.Text,

            'OSARC Contact':

                Table(

                    {

                Claims:"i:0#.f|membership|" & Lower(cmb_OSARC.Selected.DisplayName),

                Department: "",

                DisplayName: cmb_OSARC.Selected.DisplayName,

                Email: cmb_OSARC.Selected.DisplayName,

                JobTitle: "",

                Picture: ""

                    }

                ),

            'Contact Date':Date_Contact.SelectedDate,

            'Contact Time':txt_ContactTime.Text,

            'Contact Phone No':txt_ContactNumber.Text,

            'Contact Email':txt_ContactEmail.Text,

            'Contact Message':txt_ContactMessage.Text

        }

    );

            Reset(txt_ContactName);

            Reset(cmb_OSARC);

            Reset(Date_Contact);

            Reset(txt_ContactTime);

            Reset(txt_ContactNumber);

            Reset(txt_ContactEmail);

            Reset(txt_ContactMessage)

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Introducing the 2026 Season 1 community Super Users

Congratulations to our 2026 Super Users!

Kudos to our 2025 Community Spotlight Honorees

Congratulations to our 2025 community superstars!

Congratulations to the March Top 10 Community Leaders!

These are the community rock stars!

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 547

#2
WarrenBelz Profile Picture

WarrenBelz 444 Most Valuable Professional

#3
Valantis Profile Picture

Valantis 322

Last 30 days Overall leaderboard