2 Replies Latest reply: Aug 16, 2011 9:42 AM by swarup malli RSS

    Passing current selection from list box to a variable  used in straighttable

    swarup malli

      I was hoping if i could get some assistance regarding this requirment.

       

      I need to pass selected values from list box to  variable being  used in straight table.

       

      ex:

      lets say the label I'm using is 

          = vCurrentYear & ' '& 'Donors'

       

      I need to pass values from a listbox called campaignyear which contains values from 2007 to 2011. to the variable (vCurrentYear).

       

      I'm using qlikview version 9.

       

      the expression for column 2010 is :

      sum({$<CAMPAIGNYEAR = {$(=num(vCurrentYear))},TrackParm.CAMPAIGNSTATUS = {"F"},TrackParm.CAMPAIGNACCOUNT = {"18"},TrackParm.CAMPAIGNTYPE= {"empl"}>}TrackParm.NUMBEROFDONORS))

       

      the expression for column 2009 is :

      sum({$<CAMPAIGNYEAR = {$(=num(vCurrentYear -1))},TrackParm.CAMPAIGNSTATUS = {"F"},TrackParm.CAMPAIGNACCOUNT = {"18"},TrackParm.CAMPAIGNTYPE= {"empl"}>}TrackParm.NUMBEROFDONORS)).

       

       

      When I choose year 2008 , the 2 colomn expressions must show me sum of sales for year 2008 and 2007.

        if i choose 2011 , i need the expresssion to show me sum of sales for 2011 and 2010.

       

      Thank you

       

      Swarup