Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements
Attend QlikWorld 2020 and hear keynote speaker, Malcolm Gladwell. $300 savings extended to February 9th Learn More
Highlighted
Not applicable

Cyclic group selection

We have a cycle group which consists of Day, week, month, quarter, and year called g_DateSelection. This is setup as a dimension in a chart and working fine.  I would like to be able to use the selection of that cyclic group in a variable expression to perform another calculation.  For example, if on the chart, the user has selected the cyclic group and change it to display Week, can I write an expression outside this chart that will tell me that week versus day, month, etc is selected?  I tried GetCurrentFiled(g_DateSelection) but that doesn't work.  Any ideas?

Tags (1)
1 Solution

Accepted Solutions
jerem1234
Valued Contributor II

Re: Cyclic group selection

GetCurrentField(g_DateSelection) should work. Make sure you do not put single quotes around it. Just g_DateSelection (not 'g_DateSelection'). I think double quotes will work, "g_DateSelection", also. Try testing it out in a textbox and see what returns.

Hope this helps!

View solution in original post

3 Replies
jerem1234
Valued Contributor II

Re: Cyclic group selection

GetCurrentField(g_DateSelection) should work. Make sure you do not put single quotes around it. Just g_DateSelection (not 'g_DateSelection'). I think double quotes will work, "g_DateSelection", also. Try testing it out in a textbox and see what returns.

Hope this helps!

View solution in original post

Not applicable

Re: Cyclic group selection

I was able to use the first suggestion to get the selection of the cyclic group and then I used that to write an expression based on what is currently selected from the cyclic group. Thanks!

Not applicable

Re: Cyclic group selection

How did you get the current selection of the field selected in the cyclic group?