Can I use VBA to Lock VBA where Password already exists?

SusaninHouston

Active Member
Joined
Jan 13, 2005
Messages
295
I made a careless mistake and left the 'Lock project for viewing' box unchecked and sent out copies of one of my models. A project password already exists. I had just unchecked the 'Lock' box for my convenience while I did some annual updates, but then forgot to check it again before sending out the updated model.

I do have regularly scheduled VBA-driven updates. Is there any way I can use the update to re-lock the code on the base model?
 

Excel Facts

How to find 2nd largest value in a column?
MAX finds the largest value. =LARGE(A:A,2) will find the second largest. =SMALL(A:A,3) will find the third smallest
To change something in a VBA project on a given computer the "Trust access to object model of VBA project" option must be selected. By default, this option is not enabled. Without this "trust" all your effort will be in vain. When upgrading the version, go towards replacing the entire file, not its code.

Artik
 
Upvote 0

Forum statistics

Threads
1,224,818
Messages
6,181,152
Members
453,021
Latest member
Justyna P

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top