Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

How to set default selection for a user

When i open my application , in the first sheet the multi box should show one of the field value for the user logged in.

That is:

for IP user----screen selection should default to IP.

for GC user---screen selection should default to GC.

IP and GC are two value in the field 'User selection'. So when a user opens the application, based on the user it show show the selection. And later he can toggle between them(Though both the options should be available to users for toggle.)

3 Replies
jjfabian
Partner - Creator III
Partner - Creator III

Hi there,

you have to be a little more specific than that.

How do your users log in? Do you use any form of section access?

You will need to set some sort of a trigger to do this.You can probably achieve what you need by putting a trigger on your user selection field that reads the logged in user (osuser function).

Not applicable
Author

We are not having any form of section access. Just user will click the application to open. But user id are in a seperate field. Is there any way to map it when user open the application and the filed should show the group in which the user belongs.

Thanks.

jjfabian
Partner - Creator III
Partner - Creator III

Try adding a OnOpen document trigger that will perform a "select in field".

Now you will "only" have to write a little if condition for what the search string will need to be (the search string is what actually will be selected, so here you have to search for exactly the string that you want to select)

As an example, your if statement could look something like this:

=if((osuser()=YOURDOMAIN\GC),'GC',if((osuser()=YOURDOMAIN\IP),'IP'))

Of course, your formula may look a little different, but this should help you get the idea...