Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

Not applicable

Re: listbox selection to load certain data

Venkat,

Thank you.  i do understand where they come from but my issue is when i try and create them they are taken literally?  eg. if i create my variable vABC as:

if(getselectedcount(ABC)>0, concat(getfieldselections(ABC), ','), getfieldselections(ABC))

my script will not run as it will say cannot find file

abc.if(getselectedcount(ABC)>0, concat(getfieldselections(ABC), ','), getfieldselections(ABC)).qvd?

This is where i am failing in my load process.

I have a listbox of loaddates which are selectable but my expression is not calculated - it is just taken as a string?

Highlighted
Not applicable

Re: listbox selection to load certain data

hi,

i think you might providing the expression in the variable itself.

is it right ?

jagannalla
Valued Contributor III

Re: listbox selection to load certain data

Hello,

I worked out on your problem. Please check the attached file. It gives you perfect solution.

jagannalla
Valued Contributor III

Re: listbox selection to load certain data

Please go through Settings-> Doc properties -> Field Event Triggers -> For a particular field i.e <Has action >Add Action(On select)

Once you make your selections in listbox reload the application.

Not applicable

Re: listbox selection to load certain data

Hi,

Don't write your expression in variable "vABC" just leave it empty.

Consider your LoadedDate field is "CreatedDate"

Go to Document properties --> Triggers --> FieldEventTriggers

And selecte the field "CreatedDate"  and Click On Select Add  Action --> External --> Set Variable -->  Variable = vABC and Value = if(getselectedcount(ABC)>0, concat(getfieldselections(ABC), ','), getfieldselections(ABC)).

Hope now you will get the solution.

Regards
Venkat

Not applicable

Re: listbox selection to load certain data

Yes,

I think that is my issue.  I created my variable by putting my expression in the variable overview area?  Did you not do the same?

Not applicable

Re: listbox selection to load certain data

Yes , not to place the expression in the variable.

And please refer my previous post that gives a clear idea on  how and where to set the expression for variable "vABC".


Regards
Venkat

Not applicable

listbox selection to load certain data

Thank you both for your help.  I'm slightly unsure of vSample but will figure it out!

Not applicable

Re: listbox selection to load certain data

hi

vSample is some thing like just holds the individual values of "vABC"

Ex:

For Each i in 0,1,2   //First loop it will run with 0 and fetches the qvd "0.qvd" , Second loop it will run with 1 and fetches the qvd data of "1.qvd", and so on..

Load *
From C:\$(i).qvd;

Next

Now you might have an idea on the vSample.

Regards
Venkat