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

Next up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now

Reply

Dynamically Hiding Future Values in Bar Chart

Hello,

I am needing some help with the bar chart below. I am wanting to only show values for the Actuals (orange bar)  for the month we are reporting on. For example, I refreshed the report today and need to see ONLY January values. The chart is currently pulling in January and February. The refresh date will always be 1 month ahead of what I'm reporting on.

 

I'd like to build a formula that looks at today's date and automatically pulls in the prior months. So in July for example, I'm only looking at January - June for Actual amounts.

 

The Budget values (yellow bar) and Prior Year Actual values (blue line) should be shown as is, nothing needs to change there.

 

brittanyruffin_0-1706887206600.png

 

Y-Axis = 'CalendarTable'[Date]

X-Axis = Sum of 'vCorporateGandA'[Amount]

Column Ledgend = 'vCorporateGandA'[LedgerType]

brittanyruffin_1-1706887392859.png

 

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi @brittanyruffin 

 

I ran the testing as follows. Maybe it'll help you.

 

My sample:

vxuxinyimsft_0-1707100684323.png

 

vxuxinyimsft_1-1707100966928.png

 

Create a measure as follows

Measure = IF( DATEDIFF(SELECTEDVALUE('Table'[Date]), TODAY(), MONTH) >= 0 && DATEDIFF( SELECTEDVALUE('Table'[Date]), TODAY(), MONTH) <= 6, 1, 0)

 

Put the measure into the visual-level filters, set up show items when the value is 1.

vxuxinyimsft_2-1707101012482.png

Is this the result you expect?

 

If I've misunderstood you, please provide detailed sample data and the results you are hoping for: How to provide sample data in the Power BI Forum - Microsoft Fabric Community . Or show it as a screenshot or pbix. Please remove any sensitive data in advance. If uploading pbix files please do not log into your account. We can better understand the problem and help you.

 

Best Regards,
Community Support Team _Yuliax

 

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

2 REPLIES 2
Anonymous
Not applicable

Hi @brittanyruffin 

 

I ran the testing as follows. Maybe it'll help you.

 

My sample:

vxuxinyimsft_0-1707100684323.png

 

vxuxinyimsft_1-1707100966928.png

 

Create a measure as follows

Measure = IF( DATEDIFF(SELECTEDVALUE('Table'[Date]), TODAY(), MONTH) >= 0 && DATEDIFF( SELECTEDVALUE('Table'[Date]), TODAY(), MONTH) <= 6, 1, 0)

 

Put the measure into the visual-level filters, set up show items when the value is 1.

vxuxinyimsft_2-1707101012482.png

Is this the result you expect?

 

If I've misunderstood you, please provide detailed sample data and the results you are hoping for: How to provide sample data in the Power BI Forum - Microsoft Fabric Community . Or show it as a screenshot or pbix. Please remove any sensitive data in advance. If uploading pbix files please do not log into your account. We can better understand the problem and help you.

 

Best Regards,
Community Support Team _Yuliax

 

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

lbendlin
Super User
Super User

ok, what have you tried and where are you stuck?

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

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.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

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