In this blog post, we will learn different ways for Filtering SharePoint Document Library Files Based on Users, such as :
- Managing access based on specific users or user groups.
- Creating Custom Views Based on Users.
- Filter documents based on creator.
- filter documents based on assigned column
Why Filter Files Based on Users?
Filtering files based on users in a SharePoint Document Library offers several benefits such as:
- Access Control: Restricting access to specific files ensures that only authorized users can view or edit sensitive information.
- Improved Efficiency: By filtering files based on users, team members can easily find and access documents that are relevant to them, reducing time spent searching for information.
Filtering SharePoint Document Library Files Based on Users
There are several ways to filter files in a SharePoint Document Library based on users.
Using SharePoint Permissions
SharePoint allows you to control file access through permissions.
- Navigate to the Document Library: Go to the document library where the files are stored.
- Select the File or Folder: Click the ellipsis (…) next to the file or folder that you want to restrict access to.
- Choose “Manage Access”: This option will allow you to set specific permissions for users.
![image 5 | Power Platform Geeks Filtering SharePoint Document Library Files Based on Users](https://i0.wp.com/devoworx.net/wp-content/uploads/2024/11/image-5.png?resize=612%2C216&ssl=1)
- Grant Permissions to Specific Users or Groups: click start sharing, you can add or remove users and assign them either View, Edit, or can’t download permissions.
![Screenshot 2024 11 11 134159 | Power Platform Geeks Screenshot 2024 11 11 134159 | Power Platform Geeks](https://i0.wp.com/devoworx.net/wp-content/uploads/2024/11/Screenshot-2024-11-11-134159.png?resize=426%2C379&ssl=1)
- you can add or remove users and assign them either View, Edit, or can’t download permissions.
![image 6 | Power Platform Geeks Filtering SharePoint Document Library Files Based on Users](https://i0.wp.com/devoworx.net/wp-content/uploads/2024/11/image-6.png?resize=424%2C332&ssl=1)
Creating Custom Views Based on Users
You can create views that allow you to filter and display documents based on specific criteria, such as metadata, file properties, or the user who uploaded the file.
- Select “Create View”: On the library’s menu,
![Screenshot 2024 11 11 135118 | Power Platform Geeks Filtering SharePoint Document Library Files Based on Users](https://i0.wp.com/devoworx.net/wp-content/uploads/2024/11/Screenshot-2024-11-11-135118.png?resize=303%2C437&ssl=1)
- .Choose a View Type: You can create a Standard View, Datasheet View, or Calendar View, depending on how you want to display the files.
![Screenshot 2024 11 11 135138 | Power Platform Geeks Screenshot 2024 11 11 135138 | Power Platform Geeks](https://i0.wp.com/devoworx.net/wp-content/uploads/2024/11/Screenshot-2024-11-11-135138.png?resize=536%2C364&ssl=1)
- For example, to filter by user, you can choose to display files where the Created By or Modified By field matches the current user.
![image 7 | Power Platform Geeks image 7 | Power Platform Geeks](https://i0.wp.com/devoworx.net/wp-content/uploads/2024/11/image-7.png?resize=356%2C214&ssl=1)
Save and Apply the View: After defining the filters, save the view and apply it to the library. Users will now see only the files that meet the filter criteria.
Filter based on Column Assigned to
In SharePoint Document Libraries, filtering files based on specific metadata columns such as “Assigned To” can significantly streamline workflows and enhance collaboration. The “Assigned To” column typically refers to the individual or group responsible for a particular document or task, making it a powerful filter for organizing and viewing files relevant to a specific user or team.
![Screenshot 2024 11 11 140616 | Power Platform Geeks Filtering SharePoint Document Library Files Based on Users](https://i0.wp.com/devoworx.net/wp-content/uploads/2024/11/Screenshot-2024-11-11-140616.png?resize=1024%2C252&ssl=1)
Only when the user logs in and views the library, can see the files assigned to him. so we will add a person column called Assigned to verify which documents are related to which user.
![image 8 | Power Platform Geeks Filtering SharePoint Document Library Files Based on Users](https://i0.wp.com/devoworx.net/wp-content/uploads/2024/11/image-8.png?resize=518%2C402&ssl=1)
Add Filters: Under the “Filter” section in the view settings, select show items only when the following is true
and choose Assigned to column and is equal to [Me] this will display the files that only assigned to the users
![image 9 | Power Platform Geeks image 9 | Power Platform Geeks](https://i0.wp.com/devoworx.net/wp-content/uploads/2024/11/image-9.png?resize=351%2C204&ssl=1)
Now, the view will display only the documents that are assigned to the specified user(s) “the logged-in user”
![image 10 | Power Platform Geeks image 10 | Power Platform Geeks](https://i0.wp.com/devoworx.net/wp-content/uploads/2024/11/image-10.png?resize=999%2C194&ssl=1)
The [Me] dynamic content is a built-in feature in SharePoint views that automatically refers to the current logged-in user.
Now the view will display only the documents where the “Assigned To” column is equal to the current logged-in user. Whenever a user accesses this view, SharePoint automatically filters and shows them only the documents assigned to them.
See Also
- How To Use Pdf Function In PowerApps?
- Power Automate How To Check Tables, Verify Columns,extract Data From Excel
- Working With PowerApps Nested Gallery Control
- How Power Automate Create Excel Table Dynamically? | Power Automate
- How To Make A Csv File Utf-8 Encoded? | Power Automate
- How To Format Text In PowerApps? PowerApps Convert Text To Other Data Types
- Alternate Row Color In Gallery PowerApps: Simplest Way
- Check If PowerApps Contains Substring
- PowerApps If Statement And Nested If With Example
- Model Driven App With SharePoint Data Source
- PowerApps Get Day Of Week Date
Join us
- Subscribe Power Platform Geeks.