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
hmokkapati
Helper II
Helper II

Issue with Timeline slicer week selection - for Fiscal Year implementation

I have the timeline slicer implemented with below settings.

a) trying to show Fiscal Year (July to Jun)
b) Sunday being the first day of the week

I needed to show Fiscal years on the slicer and not calendar year (supposed I select Aug 2015, needs to show as Aug FY16).

Hence, I added another column using the below DAX and used that for Timeline slicer which would be the exact date after one year. (also as stated here)

TimeLine Slicer Date =
DATE ( YEAR ( DateCalendar[Date] )+1, MONTH ( DateCalendar[Date] ), DAY ( DateCalendar[Date] ))

This works fine at the Yearly/monthly level but unfortunately, not at weekly level. When I select a particular week say W28 of FY16, the days are not being selected correctly : In some cases it selects “Sun to Sat” in some cases “Sat to Fri” (based on the year).

Could you please advise how I can show fiscal dates on the slicer and make it work correctly at all the levels for all FYs. (Attaching the pbix file for reference)
Timeline slicer.PNG
Thank You,
Harish

4 REPLIES 4
Quaxdachs
Regular Visitor

Same here. I used a debugger to find out, that there are at least 3 functions for the label generation (Month, Quarter and Year).

The functions look like: 

n.prototype.generateLabel = function(e) {
  var t = this.shortMonthName(e.startDate) + " " + e.startDate.getDate() + " - " + e.year;
  return {
    title: t,
    text: e.startDate.getDate().toString(),
    id: e.index
  }
}

n.prototype.generateLabel = function(e) {
  var t = this.quarterText(e.startDate);
  return {
    title: t + " " + e.year,
    text: t,
    id: e.index
  }
}


n.prototype.generateLabel = function(e) {
  return {
    title: "Year " + e.year,
    text: e.year.toString(),
    id: e.index
  }
}

As pbiviz files basically are zip files, I decided to download the visual, unzipped it and edtited the code file. 

I thought, that replacing

 e.year

by 

(e.StartDate.getMonth() == 0 && e.StartDate.getDate() == 1)? e.year : e.year+1)

should work (at least for fiscalyears, that dont start at January 1st). 

But somehow it seems that this has no effect. After i zipped the files and imported the modified version, I didnt see any change. Is there something like a visal cache?

 

 

Regards

Kim

v-viig
Community Champion
Community Champion

@hmokkapati, This issue has been added to our backlog (#24879).

We'll investigate it deeper and fix soon.

 

@Quaxdachs, Yes, you're correct. Power BI downloads custom visuals from CDN.

To bypass our CDN you should change the GUID.

 

Please note source code of Timeline is available on GitHub.

Feel free to contribute to Timeline.

 

Ignat Vilesov,

Software Engineer

 

Microsoft Power BI Custom Visuals

pbicvsupport@microsoft.com

Anonymous
Not applicable

Has this issue been resolved? My visual is displaying incorrect year values, I have set up the Fiscal Year start month as October and Day as 1. The year value is not adjusting properly between 2018 and 2019. The fiscal year should reflect the value of 2019.

 

Day.JPGWeek.JPGMonth.JPGQuarter.JPGYear.JPG 

 

v-viig
Community Champion
Community Champion

Are you still facing this issue?

 

Can you share a Power BI report with fake data to help us in reproduing it from our side?

You can send report to our support alias: pbicvsupport@microsoft.com.

 

Ignat Vilesov,

Software Engineer

 

Microsoft Power BI Custom Visuals

pbicvsupport@microsoft.com

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.

Top Solution Authors