ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Worksheet Functions (https://www.excelbanter.com/excel-worksheet-functions/)
-   -   RENAMING WORKSHEETS (https://www.excelbanter.com/excel-worksheet-functions/151902-renaming-worksheets.html)

LEOPARDSHIDEAWAY

RENAMING WORKSHEETS
 
i have several worksheets with the weeks as the title. i need to change for
our new year. Can someone please give me the code to change the worksheets
to add 7 days to each worksheet. example 10-8 and 10-15 and 10-22 etc.

That would be very helpful

Thank you!

Bob Phillips

RENAMING WORKSHEETS
 
mpStart = 8

For Each sh In Activeworkbook.Worksheets
sh.Name = "10-" & mpStart
mpStart = mpStart + 7
Next sh

--
---
HTH

Bob

(there's no email, no snail mail, but somewhere should be gmail in my addy)



"LEOPARDSHIDEAWAY" wrote in
message ...
i have several worksheets with the weeks as the title. i need to change
for
our new year. Can someone please give me the code to change the
worksheets
to add 7 days to each worksheet. example 10-8 and 10-15 and 10-22 etc.

That would be very helpful

Thank you!





All times are GMT +1. The time now is 04:21 AM.

Powered by vBulletin® Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
ExcelBanter.com