Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

How can we pre-select two field at a time in selection list?

How can we pre-select two field at a time in selection list and will show the combined result?

7 Replies
Not applicable
Author

Do you mean using an action or simply manually?

Anonymous
Not applicable
Author

it should be pre selected in the designer part ( multbox  ) also the both should show the action too. If you can tell me in both, much appreciated

Not applicable
Author

You could either manually select them and then lock them, or I have used a button with actions associated with it to make multiple selections accross multiple list boxes. 

The syntax for making more than one selection in one list box is a little confusing but is achievable with some trial and error and something I found within the Community pages of this site.

In the search string for the actions, see below for an example:

(None|SLV|"Revenue GBP"|"Yield GBP")

Where

| denotes a separation between selections made in the list box

" are used to encase an item in the list box which contains a space

Note that it performs the required selections but creates a little wierdness in your current selections box.

Is this what you meant?

Not applicable
Author

Consider also using a bookmark for the selection. A bookmark is easy for your report users to understand and the bookmark selection can be applied as an Action if you need it to be automatic. 

Anonymous
Not applicable
Author

Thanks for the reply. However that reply doesn't full fill my answer. Let me elabrote my question with example, suppose selection list has three option in drop down menu. 1.Jan 2.Feb 3. Mar. and I want to have preselected Jan & Feb data at the begning. Of course we could have used book mark option but that actually will not work in my case.

Thanks & Regards

Shubham Kumar

Not applicable
Author

Hi Shubham,

This is what i have done in my application. Have written one macro which is being assigned to "postreload" in Document Properties.

As per perormance,this particular macro won't be time consuming also.

Macro:

sub selection_final

     call yearselect()

     call monthselect()

end sub

    

sub yearselect

     set f = ActiveDocument.GetField ("Year_Order")

     f.TopSelect "Year_Order" ,1

end sub

sub monthselect

     set f =ActiveDocument.GetField ("Month_Order")

     f.TopSelect "Month_Order" ,2                                   // number 2 means selecting two values

end sub

Note: Year_Order n Month_Order  are field names

Hope this help.

Not applicable
Author

If u want that when u open the sheet then Month should always be initially selected as Jan,Feb then u can do the following:

Go to Sheet properties>> Triggers >> OnActivateSheet >> AddActions>>Add

Action Type:Selections

Action:Select In field

Click OK

Field:Month

Search String:Jan,Feb

Then OK and Apply.