In this article, we have created User level security in Excel workbook. If you have multiple worksheets in your excel file and you want to protect/hide the data according to the user then this is very useful trick. We have used VBA code to develop this.
In this template there will be two type of roles-
- Admin: can add/delete/modified the user information and worksheet access level.
- User: User will be able to view/edit the information in the file, according to given access.
As soon as excel file will be opened it will ask to user id and password. For admin we have put the user id as “PK” and password as “xyz”. You can change is according to your requirement.