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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
sarahhaley
New Member

Trend Line on Line Chart, Option Does Not Let you change to On

Hello! I am haviong this issue on both the desktop and web versions of PowerBI. I have monthly data I want to show a trend line for, the option shows up under the analysis of the visual, but I cannot turn it to ON, if I try, it just goes back to Off each time.

 

The data I am showing is a measure I created which is actual a percentage of helpdesk tickets vs those where the SLA was met.

 

 

sarahhaley_0-1700162140966.png

 

 

I have a trend line set up for the total incidents and that works:

sarahhaley_1-1700162237367.png

 

And the met works as well:

sarahhaley_2-1700162274435.png

 

 

 

But when I use the DAX to make a percentage of what ones were met, I cannot make this have a trend line.

 

 

 

1 ACCEPTED SOLUTION
sarahhaley
New Member

To anyone who reads this, I made a new table and used the SummarizeColumns to make totals by the month, then did the percentage calc in the table. Used that field for my line chart and I was able to make a trend line. Woof.

 

 

Here was my code for the table

 

MetSLObyMonth = SUMMARIZECOLUMNS(SLO_Tickets[Year],SLO_Tickets[Month],"Incidents",sum(SLO_Tickets[IncidentCounter]),"MetSLO",sum(SLO_Tickets[MetSloCount]))

 

Here is my code for the percentage

MetSLOPercent = (MetSLObyMonth[MetSLO]/MetSLObyMonth[Incidents])*100

 

 

I still need to figure out how to concat the month/year properly, but this fixed my issue.

 

(First real report in PowerBI)

 

View solution in original post

3 REPLIES 3
sarahhaley
New Member

To anyone who reads this, I made a new table and used the SummarizeColumns to make totals by the month, then did the percentage calc in the table. Used that field for my line chart and I was able to make a trend line. Woof.

 

 

Here was my code for the table

 

MetSLObyMonth = SUMMARIZECOLUMNS(SLO_Tickets[Year],SLO_Tickets[Month],"Incidents",sum(SLO_Tickets[IncidentCounter]),"MetSLO",sum(SLO_Tickets[MetSloCount]))

 

Here is my code for the percentage

MetSLOPercent = (MetSLObyMonth[MetSLO]/MetSLObyMonth[Incidents])*100

 

 

I still need to figure out how to concat the month/year properly, but this fixed my issue.

 

(First real report in PowerBI)

 

sarahhaley
New Member

I do have this set as continuous. 

 

sarahhaley_0-1700162996438.png

 

jdbuchanan71
Super User
Super User

Make sure your X axis is set to Continuous or it won't let you turn on the trend line.

jdbuchanan71_0-1700162814291.png

 

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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