Inside my power app, I would like for Power Users only to create new entires into a sharepoint list [i.e. NewForm('EditForm1')]. Is there a way I set this permission inside the app, instead of by the share point list?
Could you please share a bit more about your scenario?
Do you only want the user to create new entries into your SP list rather than edit existing records?
Further, do you want to Restrict Users Edit permission to your SP list within your app?
I have made a test on my side, if you want to Restrict Users Edit permission to your SP list within your app, I afraid that there is no way to achieve your needs in PowerApps currently.
If you would like this feature to be added in PowerApps, please submit an idea to PowerApps Ideas Forum:
Currently, there is no way to restrict user access to a data source within a PowerApps app. We could only restrict user access via the corresponding data source. On your side, you could only restrict User Access by your SP list data source.
The way that SharePoint List is built, it is set to a version system. Through the power app, users are able to modify the records from the existing data. I want to create a button that will allow power users to create new items. I just want to know if I can restrict the option by constructing a condition in the application.
One possible way would be to have a PowerUsers SharePoint list and then lookup current user against that list, if the lookup is true, then set a PowerUser variable to true and then use that variable to control the visiblity of the "Add" button. It would not prevent them from going to SharePoint list directly and adding, but would prevent them from the PowerApp.
Now how would I ne able to get the current user? Is there a method or function that can pull the current user information? If so, this would be really helpful within the welcome screen to be a little personal each user and welcoming them when the application is opened.
I use the Office365Users connection in my PowerApp and then in the OnStart method of the opening screen to set a couple of global variables:
Then when I want to use it to for example personalize the screen I use something like this:
Hope this helps,
Continue your learning in our online communities.
Stay Up-to-Date by following PowerApps on Twitter
Let's thank our top community contributors
Features releasing from October 2019 through March 2020
Coming to a city near you
Fill out a quick form to claim your user group badge now!
Connect, share, and learn with your peers year-round
Features releasing from April 2019 through September 2019!