Opening notepad file in multiple folders, edit file and save.

stevenmccutcheon

New Member
Joined
Oct 9, 2022
Messages
1
Office Version
  1. 365
Platform
  1. Windows
Hi guys,

New to the forum, I've looked around but couldn't find anything similar.

I have a folder 'kit-server', within this is subfolders with competition names, i.e. 'Serie A', within these are subfolders with team names 'AC Milan' etc and again within them is folders named 'p1', 'p2', 'p3', 'g1'. All these folders have a config.txt inside them. I'd like to paste each config.txt into a Worksheet, edit them using my own macro then save them back to their folder. Is this possible to run a loop through all subfolders and perform this function?
 

Excel Facts

Fastest way to copy a worksheet?
Hold down the Ctrl key while dragging tab for Sheet1 to the right. Excel will make a copy of the worksheet.
Is this possible to run a loop through all subfolders and perform this function?

Welcome to MrExcel. Yes it is possible. Not simple, but possible. Assuming you are not a novice when it comes to VBA, that is.
 
Upvote 0

Forum statistics

Threads
1,215,436
Messages
6,124,869
Members
449,192
Latest member
MoonDancer

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