Skip to main content
Announcements
NEW: Seamless Public Data Sharing with Qlik's New Anonymous Access Capability: TELL ME MORE!
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

1 Solution

Accepted Solutions
avinashelite

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

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

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

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!