1 Reply Latest reply: Dec 29, 2014 5:42 AM by Vinol Joy Dsouza RSS

    GetExcludedValues from vba when ALL values are selected

    Valeriy Shylin

      Hi guys,

       

      when you apply a SELECT ALL selection on a field, you can not get its excluded values any more.

       

      My aim is to output a string with Markets which do not have data in the selected period.

      The field function GetSelectedValues works fine until SELECT ALL is applied. After this all the functions getting various values return 0 except for the GetSelectedValues. The latter one returns only the selected elements, not ALL the values.

       

      In my case I have a total of 40 markets. For January 2012 I have values for only 10 markets. Usually GetExcludedValues would return the remaining 30 values. When I select all values, GetSelectedValues function returns 10 selected markets. All the other functions (getExcludedValues, getAlternativeValues etc.) return empty arrays.

       

      Is there a way to overcome this problem?

       

      Thanks.

       

      Valera

        • Re: GetExcludedValues from vba when ALL values are selected
          Vinol Joy Dsouza

          Hi,

           

          I am trying to make a a selection from a list box which has an expression in it.

           

          I generally use the below syntax to select values from list box:-

          listbox3=Array("<value>")

           

          Set Qv = CreateObject("QlikTech.QlikView")

          Set QvDoc = Qv.OpenDoc("<QV_File_location>")

           

          QvDoc.GetSheetObject("<objectID")

          Set fz = QvDoc.Fields("objectname")

          for each v in listbox3

            fz.ToggleSelect v

          next

           

          But whenever I try to access an expression from a list box, it will have an objectID but wont have an object name  ? How can I solve for this problem ?