cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Neha2904
Helper I
Helper I

Create multiple requests using people picker on Share point form

I need to create a form where the request can be created for multiple users using the people picker combo box. 

 

So, if two users are selected, 2 records should get created in share point list.

User1.DisplayName, User1.Mail, User1.LineManager, UserType, ActionType, Role

User2.DisplayName, User2.Mail, User2.LineManager, UserType, ActionType, Role

 

Neha2904_0-1640190592318.png

 

1 ACCEPTED SOLUTION

Accepted Solutions
v-chenzhi
Community Support
Community Support

Hi @Neha2904 ,

 

Could you please show me your SharePoint List?

I assuem you have this in SharePoint and have a test on my side, please try the following workaround.

vchenzhi_0-1640253588632.png

Add an Edit form.

vchenzhi_4-1640253951753.png

 

vchenzhi_2-1640253705366.png

Add data.

vchenzhi_3-1640253747782.png

Set the Items property of ComBobox1 to:

Office365Users.SearchUser()

Set the OnChange property of ComBobox1 to:

ClearCollect(Col,ComboBox1.SelectedItems)

Add a Button, Set the OnSelect property of Button to:

ForAll(
    Col,
    Patch(
        '1222',
        Defaults('1222'),
        {
            'Full Name': ThisRecord.DisplayName,
            Email: ThisRecord.Mail,
            'Line Manager Email': Office365Users.ManagerV2(ThisRecord.Mail).mail,
            'User Type': {Value: DataCardValue5.Selected.Value},
            'Action Type': {Value: DataCardValue6.Selected.Value},
            Role: DataCardValue7.Text
        }
    )
)

 

 

Best Regards,

Zhi Chen

View solution in original post

4 REPLIES 4
Alex_10
Memorable Member
Memorable Member

@Neha2904 

 

what are the names of the comboboxes on your screenshot?

each record will have 6 columns to populate, what are the names and datatypes of those columns?

Neha2904
Helper I
Helper I

Hi @Alex_10 

Thanks for the response. The form is structured as below:

Field TypeField in PowerAppDataCard NameColumn in SPListType 
ComboboxRequested ForDataCardValue3Full NameTextMultiselection people picker
ComboboxRequested ForDataCardValue3EmailText 
ComboboxRequested ForDataCardValue3Line Manager EmailText 
ComboboxUser TypeDataCardValue11User TypeChoice 
ComboboxActionTypeDataCardValue2Action TypeChoice 
ComboboxRoleDataCardValue4RoleTextAll values of combobox are added as , separated text

 

v-chenzhi
Community Support
Community Support

Hi @Neha2904 ,

 

Could you please show me your SharePoint List?

I assuem you have this in SharePoint and have a test on my side, please try the following workaround.

vchenzhi_0-1640253588632.png

Add an Edit form.

vchenzhi_4-1640253951753.png

 

vchenzhi_2-1640253705366.png

Add data.

vchenzhi_3-1640253747782.png

Set the Items property of ComBobox1 to:

Office365Users.SearchUser()

Set the OnChange property of ComBobox1 to:

ClearCollect(Col,ComboBox1.SelectedItems)

Add a Button, Set the OnSelect property of Button to:

ForAll(
    Col,
    Patch(
        '1222',
        Defaults('1222'),
        {
            'Full Name': ThisRecord.DisplayName,
            Email: ThisRecord.Mail,
            'Line Manager Email': Office365Users.ManagerV2(ThisRecord.Mail).mail,
            'User Type': {Value: DataCardValue5.Selected.Value},
            'Action Type': {Value: DataCardValue6.Selected.Value},
            Role: DataCardValue7.Text
        }
    )
)

 

 

Best Regards,

Zhi Chen

@v-chenzhi Thankyou for the solution. It worked.

 

Helpful resources

Announcements
Power Platform Conf 2022 768x460.jpg

Join us for Microsoft Power Platform Conference

The first Microsoft-sponsored Power Platform Conference is coming in September. 100+ speakers, 150+ sessions, and what's new and next for Power Platform.

Carousel_PP_768x460_Wave2 (1).png

2022 Release Wave 2 Plan

Power Platform release plan for the 2022 release wave 2 describes all new features releasing from October 2022 through March 2023.

365 EduCon 768x460.png

Microsoft 365 EduCon

Join us for two optional days of workshops and a 3-day conference, you can choose from over 130 sessions in multiple tracks and 25 workshops.

Top Solution Authors
Users online (3,052)