cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Frequent Visitor

creating new entry in multiple lists from one powerapps page

Hi, I am trying to create a powerapp to help manage access permission to a sharepoint. The way it's been setup is  as follows:

- each item has an "access level"  value eg . A< B < C.

- I have 3 lists that document the names of people that have access to A, B and C. so lets name them level A, level B, level C

- permission on the main list are set through a flow which checks the access level value and then writes permissions based on names in the corresponding access lists. 

 

I would like to create a powerapp that helps me to manage access easier. I want the app to look-up a name and then add the names to the corresponding list Eg. 

Name box

list A  -> check

list B -> check

List C -> check

 

So if i want that name to have access to list A and B, I click the check next to both. Is that possible or is there a work-around? Thanks!

1 ACCEPTED SOLUTION

Accepted Solutions
Community Support
Community Support

Hi @bh4 :

Do you want to add the people selected by the user to multiple SharePoint lists through checkbox?

The key is to use the OnCheck property of checkbox to perform the add event.

I'v made a test for your reference:

My date sources(Level A/Level B/Level C😞

Column (click to edit) Type

TitleSingle line of text
UserPerson or Group(do not allow multiple selections)

1\add a combobox control(ComboBox1)

Items:

 

Choices('level A'.User)

 

2\add three checkbox controls

CheckboxA

Default(Check if the user already has A permission, if it is the default value is true)

 

If(IsBlank(LookUp('level A',ComboBox1.Selected.Claims=User.Claims)),false,true)

 

OnCheck(OnCheck event: add user to level A list)

 

If(IsBlank(LookUp('level A',ComboBox1.Selected.Claims=User.Claims)),Patch('level A',Defaults('level A'),{Title:"A",User:ComboBox1.Selected}))

 

OnUncheck(OnUncheck event: remove user from level A list)

 

RemoveIf('level A',ComboBox1.Selected.Claims=User.Claims)

 

CheckboxB

Default

 

 

If(IsBlank(LookUp('level B',ComboBox1.Selected.Claims=User.Claims)),false,true)

 

 

OnCheck

 

 

If(IsBlank(LookUp('level B',ComboBox1.Selected.Claims=User.Claims)),Patch('level B',Defaults('level B'),{Title:"B",User:ComboBox1.Selected}))

 

 

OnUncheck

 

RemoveIf('level B',ComboBox1.Selected.Claims=User.Claims)

 

……

37.gif

Best Regards,

Bof

View solution in original post

2 REPLIES 2
Community Support
Community Support

Hi @bh4 :

Do you want to add the people selected by the user to multiple SharePoint lists through checkbox?

The key is to use the OnCheck property of checkbox to perform the add event.

I'v made a test for your reference:

My date sources(Level A/Level B/Level C😞

Column (click to edit) Type

TitleSingle line of text
UserPerson or Group(do not allow multiple selections)

1\add a combobox control(ComboBox1)

Items:

 

Choices('level A'.User)

 

2\add three checkbox controls

CheckboxA

Default(Check if the user already has A permission, if it is the default value is true)

 

If(IsBlank(LookUp('level A',ComboBox1.Selected.Claims=User.Claims)),false,true)

 

OnCheck(OnCheck event: add user to level A list)

 

If(IsBlank(LookUp('level A',ComboBox1.Selected.Claims=User.Claims)),Patch('level A',Defaults('level A'),{Title:"A",User:ComboBox1.Selected}))

 

OnUncheck(OnUncheck event: remove user from level A list)

 

RemoveIf('level A',ComboBox1.Selected.Claims=User.Claims)

 

CheckboxB

Default

 

 

If(IsBlank(LookUp('level B',ComboBox1.Selected.Claims=User.Claims)),false,true)

 

 

OnCheck

 

 

If(IsBlank(LookUp('level B',ComboBox1.Selected.Claims=User.Claims)),Patch('level B',Defaults('level B'),{Title:"B",User:ComboBox1.Selected}))

 

 

OnUncheck

 

RemoveIf('level B',ComboBox1.Selected.Claims=User.Claims)

 

……

37.gif

Best Regards,

Bof

View solution in original post

Thanks for explaining clearly. That worked.

 

Only issue now is the annoying auto zoom when using the combo box on IPhone . It distorts the view and I can’t seem to un-zoom after selecting an user 

Helpful resources

Announcements
New Badges

New Solution Badges!

Check out our new profile badges recognizing authored solutions!

New Power Super Users

Congratulations!

We are excited to announce the Power Apps Super Users!

Power Apps Community Call

Power Apps Community Call: February

Did you miss the call? Check out the Power Apps Community Call here.

Microsoft Ignite

Microsoft Ignite

Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!

Top Solution Authors
Top Kudoed Authors
Users online (23,093)