Skip to main content
Announcements
Join us at Qlik Connect for 3 magical days of learning, networking,and inspiration! REGISTER TODAY and save!
cancel
Showing results for 
Search instead for 
Did you mean: 
sbkumar
Creator
Creator

i need to change the alignment in the code

=

chr(10) &

if(GetSelectedCount(IMS_ID_Searchable) <= 1 and GetSelectedCount(Area) = 0 and GetSelectedCount(Region) = 0 and GetSelectedCount(District) = 0 and GetSelectedCount(Territory) = 0 and GetSelectedCount(POD) = 0 and GetPossibleCount(District) > 1 , if(vAppVersion = 2, 'NATION', 'DISTRICT')) &
if(IsNull(GetCurrentSelections()), '',
if(GetSelectedCount(IMS_ID_Searchable) <= 1 and GetSelectedCount(Area) = 0 and GetSelectedCount(Region) = 0 and GetSelectedCount(District) = 0 and GetSelectedCount(Territory) = 0 and GetSelectedCount(POD) = 0 and GetPossibleCount(District) > 1, ' | ') &
if(GetSelectedCount(District) = 0 and GetPossibleCount(District) = 1, 'District : ' & Concat(DISTINCT District, ', ') & ' | ') &
replace(GetCurrentSelections(chr(13)&chr(10) , ' : ' , ' ; ' , 6 ), chr(13) & Chr(10), ' | '))

selection.PNG

 

i want the selectiosn shouldbe in specific order like  IMS_ID_Searchable :,Region,District,Area,Nation,Market,Submarket,Brand

3 Replies
Sue_Macaluso
Community Manager
Community Manager

@sbkumar Are you using QlikView or Sense? I would like to move it into the correct product forum. 

Sue Macaluso
rwunderlich
Partner Ambassador/MVP
Partner Ambassador/MVP

I can't think of a way to sort the output of GetCurrentSelections().  As an alternative, can you build up the list for specific fields using the order you want? Something like:

=if(GetSelectedCount(ProductName)
  ,'ProductName: ' & concat(DISTINCT ProductName, ', '))
& if(GetSelectedCount(Country)
  ,' | Country: ' & concat(DISTINCT Country, ', '))

-Rob
http://masterssummit.com
http://qlikviewcookbook.com
http://www.easyqlik.com

sbkumar
Creator
Creator
Author

qlikview