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: 
JoseGarcia
Creator III
Creator III

Restrict access to dashboard by using script editor

Trying to restrict access to a dashboard by using scrip editor.

In the script, as a test, i am only giving access to myself, but apparently I am missing a some part of the script.

 

Can anyone assist?

section access;
load * inline [
Access, USERID, Next/10000
Next, 10000];

 

Thanks a million 

Jose

Labels (2)
1 Solution

Accepted Solutions
QlikTom
Employee
Employee

Section Access can get complex, but if all you care about is the granting or denying access it can be simple. 

https://help.qlik.com/en-US/sense/latest/Subsystems/Hub/Content/Sense_Hub/Scripting/Security/manage-...

One of the rules is all field names and field values MUST be CAPITALIZED.

ACCESS field values can only be ADMIN or USER (ADMIN grants access to all data, USER requires some row-level filter) 

USERID must be the name of the User Directory and the Username all in CAPS with a '\' between them. 

*a word of warning, if you do this incorrectly, you could lock yourself out of the app. I suggest keeping a copy without section access in your work area. Additionally, you may store the section access table externally like any other table. (database, excel file, csv, etc.) rather than using an inline load. 

 

Section Access;
LOAD * inline [
ACCESS, USERID
ADMIN, NEXT\10000
];

Section Application;
//The rest of your script....

 

 

View solution in original post

2 Replies
QlikTom
Employee
Employee

Section Access can get complex, but if all you care about is the granting or denying access it can be simple. 

https://help.qlik.com/en-US/sense/latest/Subsystems/Hub/Content/Sense_Hub/Scripting/Security/manage-...

One of the rules is all field names and field values MUST be CAPITALIZED.

ACCESS field values can only be ADMIN or USER (ADMIN grants access to all data, USER requires some row-level filter) 

USERID must be the name of the User Directory and the Username all in CAPS with a '\' between them. 

*a word of warning, if you do this incorrectly, you could lock yourself out of the app. I suggest keeping a copy without section access in your work area. Additionally, you may store the section access table externally like any other table. (database, excel file, csv, etc.) rather than using an inline load. 

 

Section Access;
LOAD * inline [
ACCESS, USERID
ADMIN, NEXT\10000
];

Section Application;
//The rest of your script....

 

 

JoseGarcia
Creator III
Creator III
Author

Tom, 

thanks a million. It worked.

 

Jose