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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
Anonymous
Not applicable

change measure, based on what's visible in matrix visual with scrollbar

Is there a way for a measure to understand what's being shown in a visual with a scrollbar? 

Example: I have a matrix with dates for rows, with a slicer on that date. 
If someone selects a range of 6 months, for example, only 30 days will be shown in the visual, with a scrollbar allowing the user to see the rest of the date range. 

Is there a way to get the min date available in the scroll window, so I can change the title of the visual, based on the min month shown in the visual?

For example, in the visual below, I would want the title to be "February",because the min (Start of Week) shown in the visual is 2/4/2024

tnewhook_2-1705940371366.png

 

 

 

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@Anonymous , The min date in matrix you can get using measure and show that in title using fx

 

Min = minx(allselected(Date), Date[Date])

 

If you do want to scroll, consider pagination

https://www.fourmoo.com/2017/10/31/power-bi-how-to-do-pagination-in-power-bi-reports/

View solution in original post

3 REPLIES 3
v-zhengdxu-msft
Community Support
Community Support

Hi @Anonymous 

 

Unfortunately, it is not currently possible to write MEASURES based on scrollbars.

Because scrollbars does not have the function of filter;

 

However, it is possible to get the month based on the minimum date.

For your needs, I think the slicer is the optimal solution, maybe you can try this measure:

Measure = FORMAT(MIN('Table'[date]),"mmmm")
//Use the format function to format the smallest date to display as a month

Search for title in visualizations and select the fx to the right of the blank box.

Then in the What field should we base this on? box select measure.

vzhengdxumsft_0-1706000009029.pngvzhengdxumsft_1-1706000009030.png

The result is as follow:

vzhengdxumsft_2-1706000017119.png

Best Regards,

Zhengdong Xu

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

amitchandak
Super User
Super User

@Anonymous , The min date in matrix you can get using measure and show that in title using fx

 

Min = minx(allselected(Date), Date[Date])

 

If you do want to scroll, consider pagination

https://www.fourmoo.com/2017/10/31/power-bi-how-to-do-pagination-in-power-bi-reports/

Anonymous
Not applicable

The pagination idea is great - I'd never thought of doing it that way

Helpful resources

Announcements
Europe Fabric Conference

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Monthly Update - June 2024

Check out the June 2024 Power BI update to learn about new features.

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.