Good evening all.
I have gone through various guides to create a workbook that will show certain tabs depending on the users windows username. This works fine but the issue I have is that I then went to share this via OneDrive to colleagues but it doesn't seem to work the same when opening via OneDrive. The current solution is to open it and then choose to open in the desktop app which then works correctly. I assume the UserNameWindows is different in OneDrive but no matter what I try it doesn't seem to work. Does anyone have any suggestions or does OneDrive not allow this functionality?
I have used the below code and have a page on the workbook with usernames and their access levels to link it to.
Function UserNameWindows() As String ‘called from code in Auto_open, below.
UserNameWindows = Environ("UserName")
End Function
I have gone through various guides to create a workbook that will show certain tabs depending on the users windows username. This works fine but the issue I have is that I then went to share this via OneDrive to colleagues but it doesn't seem to work the same when opening via OneDrive. The current solution is to open it and then choose to open in the desktop app which then works correctly. I assume the UserNameWindows is different in OneDrive but no matter what I try it doesn't seem to work. Does anyone have any suggestions or does OneDrive not allow this functionality?
I have used the below code and have a page on the workbook with usernames and their access levels to link it to.
Function UserNameWindows() As String ‘called from code in Auto_open, below.
UserNameWindows = Environ("UserName")
End Function