Copying the first sheet from all protected workbooks in a folder

Nic2

New Member
Joined
Sep 14, 2020
Messages
5
Office Version
  1. 365
  2. 2019
Platform
  1. Windows
Hello, I need some help. This is my first time posting here so apologies if I overlook something. I'm a VBA novice and I did search for a solution but haven't been able to find anything that works for me yet.
I'm trying to copy the first sheet from 40+ department workbooks into a new consolidated workbook. All of the file names start with "2020-Q2-" and all workbooks are protected with the same password. Only the workbook structure is protected, not the file itself, no password is needed to open the file. The name of the first sheet in each workbook differs and should remain the same when copied to the new consolidated workbook.

After copying the first sheet from each department workbook to a consolidated workbook, the departmental workbook doesn't have to be protected anymore but I do want to password protect each of the department files with the same password so that they can only be opened as "Read-Only" by users without the password going forward.

Any assistance is much appreciated!
 

Excel Facts

Select all contiguous cells
Pressing Ctrl+* (asterisk) will select the "current region" - all contiguous cells in all directions.
I suggest you to use power query to consolidate all sheets into one .
 
Upvote 0

Forum statistics

Threads
1,214,430
Messages
6,119,453
Members
448,898
Latest member
drewmorgan128

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