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

July 7 - July 17 | Round 2 of the Power BI Dataviz World Championships. Don't miss your chance! Learn more

Reply
Anonymous
Not applicable

Highlight Weekends in Graphs

Greetings,

 

I'm using a stapled bar Chart to display how much Work we have to do per Day.

Dom1234_0-1683115871750.png

On the X axis there are Dates with Values, some of them stack.

Dom1234_1-1683115941565.png

All of that is used as "date hierarchy" with "Show empty elements" to visualy see days when there is nothing going on.

The down side of the "show empty elements" is that there is no work on Saturday and Sunday.

 

It would be pretty cool if the Weekends could be color coded to show at first glance that the machine isn't empty but "closed" something like this, or similar.

Dom1234_2-1683116300987.png

 

Anyone has an idea on how to do this?

 

 

 

Regards.

 

 

2 REPLIES 2
Anonymous
Not applicable

Okay... that does seem like what i'm looking for, thanks.

 

Now how would one properly enter this formula?

 

WeekDayWeekEnd = SWITCH('Contact Us Page'[Day of Week],5,SUMX('Contact Us Page','Contact Us Page'[Users]),6,SUMX('Contact Us Page','Contact Us Page'[Users]))​

 

 

i assume creating a new measure with those values should work?

Thats the only way i can open this "edit" field.

Dom1234_0-1683123515922.png

 

DataWeekEnd = SWITCH('pb_pps_data plan_step_attrs'[production_date],5,SUMX('pb_pps_data plan_step_attrs','pb_pps_data plan_step_attrs'[production_time]),6,SUMX('pb_pps_data plan_step_attrs','pb_pps_data plan_step_attrs'[production_time]))​

 

 

but for some reason it doesnt work...

Dom1234_2-1683124111825.png

 

i assume thats because i'm missing the "day of week" value that would allow me to find Weekends?

ribisht17
Super User
Super User

@Anonymous 

 

You can do something similar

 

https://community.powerbi.com/t5/Desktop/Line-Chart-to-highlight-Weekends/m-p/2127132

 

Regards,

Ritesh

 

 

Helpful resources

Announcements
FabCon and SQLCon Barcelona 2026

FabCon & SQLCon – Barcelona 2026

Join us in Barcelona for FabCon and SQLCon, the Fabric, Power BI, SQL, and AI community event. Save €200 with code FABCMTY200.

July Power BI Update Carousel

Power BI Monthly Update - July 2026

Check out the July 2026 Power BI update to learn about new features.

60 days of Data Days Carousel

Data Days 2026

Join Data Days 2026: 60 days of free live/on-demand sessions, challenges, study groups, and certification opportunities.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Top Solution Authors