Skip to main content
Woohoo! Qlik Community has won “Best in Class Community” in the 2024 Khoros Kudos awards!
Announcements
Nov. 20th, Qlik Insider - Lakehouses: Driving the Future of Data & AI - PICK A SESSION
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Transfer external parameter by section access.

I have a lot of parameters which want to be transfered to qvw. I want to transfer them by section access.

section access;

load USERID, ACCESS, link from a.xls.....

section application;

load link from a.xls;

load A, B,  parameter1, parameter2 ....

I think if a user login with a useraccount. I can get the field of parameter1, 2.... Then I set the parameters to qlikview varibles in action(OnActiveSheet)

Every thing same to be OK. In trigger page(OnActiveSheet)

action 1: select field A in value 'link'  ------ A = link

action 2: set varable : v1=parameter1  

action 3: set varable : v2=parameter2

action 4: set varable : v=B

And now I can use varables in my QV file.  BUT the fact is THIS IS NOT WORK WELL.  Who can help and give me some advice on this. thank you .

21 Replies
Not applicable
Author

I wanna varable set in OnActiveSheet action. But I set up qvw file, it does not work. If need, I can upload my file.

erichshiino
Partner - Master
Partner - Master

Hi, I don't think you can send some parameters directly.

So I created a data island with the parameters and used section access to reduce it. So each user will only get one set of parameters.

After that, I created the macros using the values on the fields.

I hope the sample app can help you.

To open the App use:

USER: A

Password: A

or

USER: B

Password: B

OR

USER: C

Password: C

Regards,

Erich

Not applicable
Author

Hi Erich,

Thank you for your reply.

It works, but not reach my demand.

In your example file , I can trigger the action by click another sheet. I want to set the varible when document first opened without any user click or select.

So I try to set document trigger onopenaction to open a certain sheet when document opened everytime. And set actions in OnActiveSheet to make select field and set varibles. But CANNOT work. I 'm confused  about this. Please help me. Thank you.

Not applicable
Author

Hi.

Set trigger on Change Other Variable with content "=now(1)"

Not applicable
Author

Hi where is on Change Other Variable?

Not applicable
Author

In document propertis on sheet Variables create variable with name "aaaa", With value "=now(1)"

In document propertis on sheet Trigger set trigger OnChange for variable "aaaa". This trigger

action 1: select field A in value 'link'  ------ A = link

action 2: set varable : v1=parameter1  

action 3: set varable : v2=parameter2

action 4: set varable : v=B

Not applicable
Author

I think I know your idea. If I set a variable to =now(1) , the qv will call the action every second. I think it will slow down the system speed. I will try this may be set to =now(2) is better. I'll try it later.

Not applicable
Author

Hi,

May I know why do you want to set those parameters to another variable when you can directly use those paramaters? Do you want to use those parameters for hiding a sheet or chart?

You need to transfer the parameters through section access.

For example, you are using P1 as a parameter field for hiding a sheet and you have 1 as a value for user A and 0 as a value for user B. You can directly use the parameter field and its value. You need to goto sheet properties, then goto general tab, then goto the show sheet, select conditional and write sum(P1)=1. When the user A logs in the sheet will be displayed but it will be hidden for user B.

Hope you can now figure out how to use these parameters directly.

Hope this answers your query else let me know

Best Regards,

Sajeevan

Not applicable
Author

Hi Sajeevan, I don't transfer parameter to variable for hiding a sheet but other purpose. I have a table with several fields( ID, City, State, ........). When a user login as John for example, I want QV 'remember' John 's ID, City , State , and transfer these to variable. And then I can use these variable in set analysis expression. Thank you and hope your reply.