Power BI is turning 10! Tune in for a special live episode on July 24 with behind-the-scenes stories, product evolution highlights, and a sneak peek at what’s in store for the future.
Save the dateEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends August 31st. Request your voucher.
Hi There,
I am stuck in one problem where my requirement is if its weeken my report will only show page for Weeknd, IF its Saturday my report page should only be visible for Saturday and other days report page should be hidden and if its Sunday then my weekdays and Saturday report page should be hidden.
IS there anything we can do to create a report page like this?
Eg if i am opening report on Monday to Friday ,Only Weekday Page should appear :
If its Saturday then only "Saturday" page will open:
If Sunday then Only "Sunday" page should open rest other page should be hide:
Can anyone help me in reaching this?
Thanks in advance!
Ashish
@SamWiseOwl
@Ashish_Mathur
@amitchandak
Solved! Go to Solution.
I don't believe you can hide pages.
Instead you could have buttons whose text and action is based on the day of the week.
Button destination =
Switch(
true()
,Weekday(Today(),2) < 6 --If weekday
,"Weekdays"
,Weekday(Today(),2) = 6
,"Saturday"
,"Sunday")
Use this for the button destination and the button text
If you are happy with this answer please mark as a solution for others to find !
Kudos are always appreciated! Check out our free Power BI video courses.
Hi @ashicool_10061 ,
As SamWiseOwl said page level security is not possible. But there is an alternative for you to consider:
(1) This is my test data.
(2) We can create two columns.
Weekday = WEEKDAY([Date],2)
Column = IF([Weekday]<=5 && [Weekday]>1,1,[Weekday])
(3) Click Manage Roles on the Modeling tab.
var _a=WEEKDAY(TODAY(),2)
var _b=SWITCH(TRUE(),
_a<=5 && _a>=1,1,
_a=6,6,
_a=7,7)
RETURN [Column]=_b
(4) View as "Untitled".
Today is Monday, so output the data for Monday through Friday. For more information about RLS you can refer to:
Row-level security (RLS) guidance in Power BI Desktop - Power BI | Microsoft Learn
Row-level security (RLS) with Power BI - Microsoft Fabric | Microsoft Learn
Best Regards,
Neeko Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @ashicool_10061 ,
As SamWiseOwl said page level security is not possible. But there is an alternative for you to consider:
(1) This is my test data.
(2) We can create two columns.
Weekday = WEEKDAY([Date],2)
Column = IF([Weekday]<=5 && [Weekday]>1,1,[Weekday])
(3) Click Manage Roles on the Modeling tab.
var _a=WEEKDAY(TODAY(),2)
var _b=SWITCH(TRUE(),
_a<=5 && _a>=1,1,
_a=6,6,
_a=7,7)
RETURN [Column]=_b
(4) View as "Untitled".
Today is Monday, so output the data for Monday through Friday. For more information about RLS you can refer to:
Row-level security (RLS) guidance in Power BI Desktop - Power BI | Microsoft Learn
Row-level security (RLS) with Power BI - Microsoft Fabric | Microsoft Learn
Best Regards,
Neeko Tang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous
Thank you for this suggestion . I will look into this .
Thanks,
Ashish
I don't believe you can hide pages.
Instead you could have buttons whose text and action is based on the day of the week.
Button destination =
Switch(
true()
,Weekday(Today(),2) < 6 --If weekday
,"Weekdays"
,Weekday(Today(),2) = 6
,"Saturday"
,"Sunday")
Use this for the button destination and the button text
If you are happy with this answer please mark as a solution for others to find !
Kudos are always appreciated! Check out our free Power BI video courses.
Hi @SamWiseOwl ,
Appreicate your help . I will try if this will for for me.
Thank you for your help.
Ashish