Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
stjernvd
Partner - Creator
Partner - Creator

Dynamic Chart Name

Hi,

I want to make my chart name dynamic in the sense that when I click on the stock and year, the name in the chart changes according to what stock and year is selected. If none are selected I want the title to be 'Stock Performance 2012-2014'.

How can I do this? (also how do I enter a space between dimension names in a chart title?)

Labels.PNG

Title.PNG

Error.PNG

Thanks

Danielle

Labels (1)
1 Solution

Accepted Solutions
avinashelite
MVP
MVP

if your stocks are single select than you can use sunindia‌ expression , if its a multi select you can try like :

If(GetSelectedCount(Year) = 0 and GetSelectedCount(Stock) = 0, 'Stock Performance 2012-2014',

getfieldselection(Year,'|')&'-'&getfieldselection(Stock,'|'))

View solution in original post

4 Replies
sunny_talwar
MVP
MVP

Try this:

If(GetSelectedCount(Year) = 0 or GetSelectedCount(Stock) = 0, 'Stock Performance 2012-2014', Stock & Year)


If(GetSelectedCount(Year) = 0 or GetSelectedCount(Stock) = 0, 'Stock Performance 2012-2014', Stock & ' ' & Year)

sunny_talwar
MVP
MVP

Or may be this:

If(GetSelectedCount(Year) = 1 and GetSelectedCount(Stock) = 1, Stock & Year, 'Stock Performance 2012-2014')


If(GetSelectedCount(Year) = 1 and GetSelectedCount(Stock) = 1, Stock & ' ' & Year, 'Stock Performance 2012-2014')

avinashelite
MVP
MVP

if your stocks are single select than you can use sunindia‌ expression , if its a multi select you can try like :

If(GetSelectedCount(Year) = 0 and GetSelectedCount(Stock) = 0, 'Stock Performance 2012-2014',

getfieldselection(Year,'|')&'-'&getfieldselection(Stock,'|'))

stjernvd
Partner - Creator
Partner - Creator
Author

Thank you!