Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
sonuojha1
Helper IV
Helper IV

How to Show/Hide Filters on Report based on who logged into Power BI ( RLS)?

Hello All,

 

I have a report with Employee Salary and benifits information, it has filters like Employee Number, Employee Name etc. by using those filters I can see any employee's salary and other details.

My user wants to apply a security, if managers can login to report, they can see all the filters and data. But when a director login, he shouldn't filter out data based on employee name/number etc. 

I would like to deny director to filter data for any specific employee. Even I don't want to show him any filters. 

 

if logged in user is director then disable and hide the filter

else enable and show the filter on report.

 

 

sonuojha1_0-1612878350691.png

 

Thanks in advance.

 

Regards,

Sonu

1 ACCEPTED SOLUTION
Icey
Community Support
Community Support

Hi @sonuojha1 ,

 


if logged in user is director then disable and hide the filter

else enable and show the filter on report.


If they are using "Slicers" to filter report, try to use a Card visual to work as a mask to hide the slicers based on RLS like so:

 

 If you want to prevent multiple clients from viewing the slicers, try to create a client table with Email/PBI account. And then, hide the table. Create measures like so:

Make Transparent =
VAR CurrentUser =
    USERPRINCIPALNAME ()
RETURN
    IF ( CurrentUser IN VALUES ( clinet[email] ), "Black", "#FFFFFF00" )

Transparent = "#FFFFFF00"

 

If just one client, use this one:

Make Transparent =
VAR CurrentUser =
    USERPRINCIPALNAME ()
RETURN
    IF ( CurrentUser = “xxxx@mail.com”, "Black", "#FFFFFF00" )

Transparent = "#FFFFFF00"
Measure = 1

 

Note: you can replace Black with your report background color.

 

 

2. Create visuals.

 

 

 

3. For test, I manage roles. But in your scenario, it is unnecessary.

 

 

BTW, .pbix file attached.

 

 

Best Regards,

Icey

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

4 REPLIES 4
Icey
Community Support
Community Support

Hi @sonuojha1 ,

 


if logged in user is director then disable and hide the filter

else enable and show the filter on report.


If they are using "Slicers" to filter report, try to use a Card visual to work as a mask to hide the slicers based on RLS like so:

 

 If you want to prevent multiple clients from viewing the slicers, try to create a client table with Email/PBI account. And then, hide the table. Create measures like so:

Make Transparent =
VAR CurrentUser =
    USERPRINCIPALNAME ()
RETURN
    IF ( CurrentUser IN VALUES ( clinet[email] ), "Black", "#FFFFFF00" )

Transparent = "#FFFFFF00"

 

If just one client, use this one:

Make Transparent =
VAR CurrentUser =
    USERPRINCIPALNAME ()
RETURN
    IF ( CurrentUser = “xxxx@mail.com”, "Black", "#FFFFFF00" )

Transparent = "#FFFFFF00"
Measure = 1

 

Note: you can replace Black with your report background color.

 

 

2. Create visuals.

 

 

 

3. For test, I manage roles. But in your scenario, it is unnecessary.

 

 

BTW, .pbix file attached.

 

 

Best Regards,

Icey

 

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Thanks Icey, for your suggestion. I think it is close to the expectation. I'll try this logic with my dataset and mark this as a solution if it worked.

 

Regards,

Sonu

Icey
Community Support
Community Support

Hi @sonuojha1 ,

 

Does it work in your scenario?

 

 

Best Regards,

Icey

amitchandak
Super User
Super User

@sonuojha1 , RLS is Data level. Perspective is at visual level

https://powerbi.microsoft.com/en-us/blog/power-bi-desktop-august-2020-feature-summary/#_Perspectives

 

I think you have to create a page and hide and show by this method

https://www.fourmoo.com/2020/05/26/did-you-know-you-can-now-selectively-show-report-pages-for-specif...

Share with Power BI Enthusiasts: Full Power BI Video (20 Hours) YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 2025 Power BI update to learn about new features.

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors
Top Kudoed Authors