A family of Microsoft spreadsheet software with tools for analyzing, charting, and communicating data.
Hi,
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Hi everyone,
I have a vba code. The code runs well. But when I tried to protect sheet, it prompts me runtime error 1004.
I did a google search and in the macro setting, I checked the option "trust access to the VBA project object model".
I also checked the option "enable all macros.
However the error still persisted until I unprotected the worksheet.
My question: how to protect the worksheet and keep the vba code running well?
Thank you,
Ben Lee
A family of Microsoft spreadsheet software with tools for analyzing, charting, and communicating data.
Locked Question. This question was migrated from the Microsoft Support Community. You can vote on whether it's helpful, but you can't add comments or replies or follow the question.
Answer accepted by question author
Hi Ronse,
Awesome. The code works perfectly and no more errors.
I was just missing that piece and that excel looked like it was going to fail.
You are indeed truly an expert.
Thank you very much.
Best Regards,
Ben Lee