Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have two user groups with separate logins to my QVW.
How can I alter the apperance of certain objects based on a users access login?
Many Thanks
Just create a simple inline table with fields in all-caps like this:
myIsland:
LOAD * INLINE [
HIDEFLAG
1
0
];
Then in section access, you can have something like this for example:
NTNAME | ACCESS | HIDEFLAG |
BOB | USER | 1 |
DAVE | ADMIN | 0 |
If you have a listbox you want to hide, under Layout make the conditional show condition max({1} HIDEFLAG)=0
Regards,
Vlad
Brian,
The simplest way to do that would be to create an island that contains one or more flags. Add these flag values to your section access reduction fields. Then hide/show objects based on whether a flag value exists.
Regards,
Vlad
Thanks for the help, how can I create an Island with flags?
Just create a simple inline table with fields in all-caps like this:
myIsland:
LOAD * INLINE [
HIDEFLAG
1
0
];
Then in section access, you can have something like this for example:
NTNAME | ACCESS | HIDEFLAG |
BOB | USER | 1 |
DAVE | ADMIN | 0 |
If you have a listbox you want to hide, under Layout make the conditional show condition max({1} HIDEFLAG)=0
Regards,
Vlad
Thats great, thank you
I have one question..
Can you explain this code - max({1} HIDEFLAG)=0
Is there another way of saying - =IF(HIDEFLAG=0, listbox.visible = False)
I know that isnt the correct code, but is there something similar?
Thanks
Well, almost. Section Access works like any other table in QlikView in terms of reductions--except that the reductions are permanent. So the section access code above will ensure that when BOB logs in, the HIDEFLAG value in the data model will only have a value of 1. Therefore, max({1} HIDEFLAG)=0 will return false and the listbox will be hidden.
Glad to help--please verify correct answers
Vlad
Like to give an example of this. The attach document has three users and based on the user it will either show or hide the SalesPerson List Box.
Dave is the Admin and will see the list box
Bob is a User and will not see the list box
Bill is a User and will see the list box.
This is based on the code that Vlad provided. The Condition to show or hide the list box is on the Layout Tab under the List Box properties.
Bill