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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
Anonymous
Not applicable

Constant line value that changes with Slicer selection

I am trying to create a constant line that changes value based on the Slicer selection, I have a Switch statement that assigns the value and the line value appears correctly on the line tooltip but the line isn't displaying at the correct value or moving at all.

My Switch statement is:

 

 

 

 

Flat Line = 
SWITCH(
SELECTEDVALUE('Table'[Column]),
"P" , 85,
"G", 80,
"U", 80
)

 

 

 

 

 

Line Behavior:

image.pngimage.png

9 REPLIES 9
Anonymous
Not applicable

I see that now, Is it possible to assign the Y-axis values for the line?

Hi @Anonymous ,

 

Try the feature:

jj11.PNG

 

Best regards,
Lionel Chen

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

 

 

Anonymous
Not applicable

Toggling that option changes which side the Y-axis for the column data is on (left to right), then the line values just changes to whichever side the column data isn't on, and I don't see any options for changing the line Y-axis under that menu.

Hi @Anonymous ,

 

ccc9.PNG

When the range of line and Y-axis values are similar, they will be merged into a coordinate system. This is automatically controlled by the software, and we have no way to change it.

 

Best regards,
Lionel Chen

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

 

 

v-lionel-msft
Community Support
Community Support

Hi @Anonymous ,

 

The left Y axis is for labeling Columns values,

ii5.PNG

and the right Y axis is for labeling Line values

ii6.PNG

 

Best regards,
Lionel Chen

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

Greg_Deckler
Super User
Super User

That's really odd, do you have Flat line in the Line values part of your column and line chart? That's where it should be.

@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Mastering Power BI 2nd Edition

DAX is easy, CALCULATE makes DAX hard...
Anonymous
Not applicable

I do.

 

image.png

Oh, I see what's going on, your line and axis is changing. (the Y axis on the right). Therefore, you cannot judge the position of the line by the axis and left, you have to judge by the y axis of the right.

@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Mastering Power BI 2nd Edition

DAX is easy, CALCULATE makes DAX hard...

Oh, I see what is going on, your line y-axis is changing. (the right-hand y-axis). So, you can't judge the position of the line by the left y axis, you have to judge it by the right-hand y axis.

@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Mastering Power BI 2nd Edition

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

Find out what's new and trending in the Fabric Community.