Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi all,
I want to show/hide sheets to some user according to their profile.
for example : if profile = profile 1 show sheet 1 & 3
if profile = profile 2 show sheet 2 & 3 & 4
I already done this in one sheet conditional : ( it worked)
if(match(Upper(OSUser()),'domain\user1')>0,1,0)
but since I have several users I can't add them one by one and instead I would like to assign each user profile the tabs they should see.
Thank you in advence
You can set a variable in load script based on some dictionary file and then in sheet settings refer to variable.
perm:
load sheetName, concat(chr(39) & userName & chr(39), ',') as permresident userToSheetsPerms group by sheetName;
let sheetPerm = peek('perm',0,'perm');
then in settings:
if(match(Upper(OSUser()),$(sheetPerm ))>0,1,0)
If you've more sheets it will require mode dynamic variable names.