![]() |
lock a cell from users but not macros
I have a work sheet my macro copys data into. When i just protect the sheet
the macro will not run. Is there a way to lock it so the macro will still work but the users can not edit the data. Thank you |
lock a cell from users but not macros
Hi
Unprotect the sheet at the top of the macro and then re-protect at the end. Regards, Per "Miree" skrev i meddelelsen ... I have a work sheet my macro copys data into. When i just protect the sheet the macro will not run. Is there a way to lock it so the macro will still work but the users can not edit the data. Thank you |
lock a cell from users but not macros
Is there a way to get this to work with a password? when i tried to do it
with password it needed a user input, to unprotect, i dont want my users to have the password. Also it doesn't lock with a pass word "Per Jessen" wrote: Hi Unprotect the sheet at the top of the macro and then re-protect at the end. Regards, Per "Miree" skrev i meddelelsen ... I have a work sheet my macro copys data into. When i just protect the sheet the macro will not run. Is there a way to lock it so the macro will still work but the users can not edit the data. Thank you |
lock a cell from users but not macros
Try this
ActiveSheet.Unprotect Password:="MyPass" ' do things ActiveSheet.Protect Password:="MyPass" Mike "Miree" wrote: Is there a way to get this to work with a password? when i tried to do it with password it needed a user input, to unprotect, i dont want my users to have the password. Also it doesn't lock with a pass word "Per Jessen" wrote: Hi Unprotect the sheet at the top of the macro and then re-protect at the end. Regards, Per "Miree" skrev i meddelelsen ... I have a work sheet my macro copys data into. When i just protect the sheet the macro will not run. Is there a way to lock it so the macro will still work but the users can not edit the data. Thank you |
lock a cell from users but not macros
Use this syntax:
ActiveWorkbook.Unprotect Password:="JustMe" ActiveWorkbook.Protect Password:="JustMe" Regards, Per "Miree" skrev i meddelelsen ... Is there a way to get this to work with a password? when i tried to do it with password it needed a user input, to unprotect, i dont want my users to have the password. Also it doesn't lock with a pass word "Per Jessen" wrote: Hi Unprotect the sheet at the top of the macro and then re-protect at the end. Regards, Per "Miree" skrev i meddelelsen ... I have a work sheet my macro copys data into. When i just protect the sheet the macro will not run. Is there a way to lock it so the macro will still work but the users can not edit the data. Thank you |
lock a cell from users but not macros
Perfect thank you
"Mike H" wrote: Try this ActiveSheet.Unprotect Password:="MyPass" ' do things ActiveSheet.Protect Password:="MyPass" Mike "Miree" wrote: Is there a way to get this to work with a password? when i tried to do it with password it needed a user input, to unprotect, i dont want my users to have the password. Also it doesn't lock with a pass word "Per Jessen" wrote: Hi Unprotect the sheet at the top of the macro and then re-protect at the end. Regards, Per "Miree" skrev i meddelelsen ... I have a work sheet my macro copys data into. When i just protect the sheet the macro will not run. Is there a way to lock it so the macro will still work but the users can not edit the data. Thank you |
All times are GMT +1. The time now is 02:59 AM. |
Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
ExcelBanter.com