Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Rick_T
Contributor III
Contributor III

Dynamic label field based on a variable

Hello everyone, 

I made a variable which serves as a input for a specific month. So when i click on a month the visuals adapt and show the data of the selected month. So far so good. Now I am trying to achieve the same dynamic ability with the label of the dimension c.q. measure. 

I am using the following expression: 

='Omzet'&' '&date(vMaand, 'MMMM') &' '&vJaarVorig

The green part works fine but I can't get the red part to work together with the selected variable. When I only use the vMaand variable without the date(......, 'MMMM') it works but it shows a short month name notation. I want it to show the full month name. Does anyone know how I can achieve this? 

 

Sincerely, 

Rick 

Labels (1)
1 Solution

Accepted Solutions
jmartineze
Partner - Creator
Partner - Creator

Try change it in the number tabs, select dimension,press formar settings Date option and add MMMM in the format pattern box.

 

J.

View solution in original post

4 Replies
jmartineze
Partner - Creator
Partner - Creator

Hello Rick,

the month name it depends on your variables in the begin on the script, you must change it.

SET MonthNames='Jan;Feb;Mar;Apr;May;Jun;Jul;Aug;Sep;Oct;Nov;Dec'

change by

SET MonthNames='January;February;   etc...

 

J.

Rick_T
Contributor III
Contributor III
Author

Hello J, 

Thanks for your quick and helpful reply. This will be my final option because right now my whole dashboard is build upon the short variable names. If I change these I will have to check every expression I made. Normally I can work around this by changing the short month names with long ones by  'MMMM' in the expression, but this is not possible in the way I try it now? 

Sincerely, 

Rick 

jmartineze
Partner - Creator
Partner - Creator

Try change it in the number tabs, select dimension,press formar settings Date option and add MMMM in the format pattern box.

 

J.

Rick_T
Contributor III
Contributor III
Author

Hi J, 

Found the error, I needed to format the actual short month name in the set expression correctly. 

Used 'MMM' right now but all the short month names are formatted with a dot at the end so 'MMM.' was the correct way. 

Thanks for your replies. 

Sincerely, 

Rick