Qlik Community

QlikView Layout & Visualizations

Discussion Board for collaboration on QlikView Layout & Visualizations.

Display Listbox based on $Field Selection Dynamically

Hi Guys,

I need to display the listbox based on the $Field selection. The listbox should display with the order(like $FieldNo). see the below screen shot for reference.

QV_Help1.JPG

ttached the sample file.

1 Solution

Accepted Solutions
MVP
MVP

Re: Display Listbox based on $Field Selection Dynamically

Hi,

Use this expression for the list boxes

=$(=SubField(GetFieldSelections($Field, '|'), '|', 1))

=$(=SubField(GetFieldSelections($Field, '|'), '|', 2))

=$(=SubField(GetFieldSelections($Field, '|'), '|', 3))

Hope this helps you.

Regards,

Jagan.

12 Replies
greeshma_k
Contributor III

Re: Display Listbox based on $Field Selection Dynamically

Try adding a condition in the layout tab using GetFieldSelections().

naveen_y19
New Contributor II

Re: Display Listbox based on $Field Selection Dynamically

Right Click on properties for each List box, in the properties page goto Layout Tab --> Select Show Conditional and put the following condition in it "=if($Field='Ctype', True(), False())"

do the same thing for

From --> =if($Field='From ', True(), False())

Product --> =if($Field='Product ', True(), False())

Re: Display Listbox based on $Field Selection Dynamically

Hi Naveen,

Thanks. But i have more than 300 Fields. The user will select the Field, based on their need.

is any other way to do this?

MVP
MVP

Re: Display Listbox based on $Field Selection Dynamically

Dsiplay condition, like:

Max(If($Field='Ctype',1,0))=1

PFA

Re: Display Listbox based on $Field Selection Dynamically

Thanks Tressco. I have more than 300 fields. My attached was just for sample.

need to display the Listbox, anywhere in the $Field Selection.

MVP
MVP

Re: Display Listbox based on $Field Selection Dynamically

So you don't want to write this condition for all these 300 list boxes, right? I am afraid, that effort might not be bypassed.

Re: Display Listbox based on $Field Selection Dynamically

I can use the expression =$(=$Field) in the Listbox Expression. But this is working for only one selection.

If i select more than one Field, the listbox should display nearby Previous Listbox. find the attached please

MVP
MVP

Re: Display Listbox based on $Field Selection Dynamically

Hi,

Use this expression for the list boxes

=$(=SubField(GetFieldSelections($Field, '|'), '|', 1))

=$(=SubField(GetFieldSelections($Field, '|'), '|', 2))

=$(=SubField(GetFieldSelections($Field, '|'), '|', 3))

Hope this helps you.

Regards,

Jagan.

MVP
MVP

Re: Display Listbox based on $Field Selection Dynamically

The way you trying is fine. And that would only work for one selection, because you are defining expression of one listbox, so based on your selection you can get a different field value in a list box but not many list boxes.

Community Browser