Forum Discussion
Error in card with weeks
- 4 years ago
Hola Antonio_Gomez
You'll need to use a measure then to display the correct First and Last Values. See below. Hopefuly this solves it finally for you.
I've created two measures:Semana-Año Primero =VAR vUltima = MAX(Calendar_Months[calendar_dt])VAR vPrimero = MIN(Calendar_Months[calendar_dt])RETURN"Semana " & FORMAT(WEEKNUM(vPrimero),"0#") & "/" & YEAR(vPrimero)Semana-Año Ultima =VAR vUltima = MAX(Calendar_Months[calendar_dt])VAR vPrimero = MIN(Calendar_Months[calendar_dt])RETURN"Semana " & FORMAT(WEEKNUM(vUltima),"0#") & "/" & YEAR(vUltima)
Hello Signore_Ands
I'm really glad you are helping me. Now, I understand the adding leading zeros, thanks.
I did it but only works for me if I switch Week/Year to Year/Week when the range is in differents year.
= Table.AddColumn(#"Changed Type1", "Semana-Año", each "Semana " & Number.ToText(Date.Year([Dia])) & "/" & Number.ToText(Date.WeekOfYear([Dia]),"D2"))
= Table.AddColumn(#"Changed Type1", "Semana-Año", each "Semana " & Number.ToText(Date.WeekOfYear([Dia]),"D2") & "/" & Number.ToText(Date.Year([Dia])) )
I think it's because the order is given only by the week number.
Hola Antonio_Gomez
You'll need to use a measure then to display the correct First and Last Values. See below. Hopefuly this solves it finally for you.
I've created two measures:
- Antonio_Gomez4 years agoResolver I
It works, you are the best!