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

Announcements
See why IDC MarketScape names Qlik a 2025 Leader! Read more
cancel
Showing results for 
Search instead for 
Did you mean: 
helen_pip
Creator III
Creator III

A Text Box to show to show either or

Dear Qlikview User

I have a text box which is acting as a Title to the page, but also acts as a current selections box

My code is as follow:

if (GetSelectedCount(YearStart)>=1, ' ● ' & YearStart)

&

if (GetSelectedCount(QuarterName)>=1, ' ● ' & QuarterName)

&

if (GetSelectedCount(Month)>=1, ' ● ' & Month)

The code will show the value of what the user selected.  However, if the user has selected a Year value and then goes onto select a Month value, I want their previous selection on "Year" to no longer be visible in the text box

Almost like a show/hide within a text box

Is this possible?

Kind Regards

Helen

5 Replies
sunny_talwar

May be you need this:

If(GetSelectedCount(Month)>=1, ' ● ' & Month,

     If(GetSelectedCount(QuarterName) >= 1, ' ● ' & QuarterName,

          If(GetSelectedCount(YearStart)>=1, ' ● ' & YearStart)))

MarcoWedel

Hi,

maybe also possible:

If(GetSelectedCount(YearStart) and not GetSelectedCount(QuarterName) and not GetSelectedCount(Month), ' ● ' & YearStart)

&

If(GetSelectedCount(QuarterName) and not GetSelectedCount(Month), ' ● ' & QuarterName)

&

If(GetSelectedCount(Month), ' ● ' & Month)

hope this helps

regards

Marco

helen_pip
Creator III
Creator III
Author

Hello Marco

Thank you for your response

This technique could work for me.  However, my text box also has to include the values from the master calender

With the technique you have kindly shared, how would I incorporate the following code into the same technique ( I have been trying to get it to work since yesturday)

if(v_Start_Date_OP,

  if (v_End_Date_OP,

  Date(v_Start_Date_OP, 'DD/MM/YYYY - ') & Date(v_End_Date_OP, 'DD/MM/YYYY '),

  Date(v_Start_Date_OP, 'DD/MM/YYYY - ')

  ),

  if (v_End_Date_OP,

  Date(v_End_Date_OP, '- DD/MM/YYYY '),

  ''

  )

)

& ....................

helen_pip
Creator III
Creator III
Author

Hello SunnyT

Thank you for your response

This technique could work for me.  However, my text box also has to include the values from the master calender

With the technique you have kindly shared, how would I incorporate the following code into the same technique ( I have been trying to get it to work since yesturday)

if(v_Start_Date_OP,

  if (v_End_Date_OP,

  Date(v_Start_Date_OP, 'DD/MM/YYYY - ') & Date(v_End_Date_OP, 'DD/MM/YYYY '),

  Date(v_Start_Date_OP, 'DD/MM/YYYY - ')

  ),

  if (v_End_Date_OP,

  Date(v_End_Date_OP, '- DD/MM/YYYY '),

  ''

  )

)

& ....................

sunny_talwar

Not sure I understand, what are you looking to get? Can you may be provide some sample data with the output?