horizonflame
Board Regular
- Joined
- Sep 27, 2018
- Messages
- 186
- Office Version
- 2013
Hi
I have a workbook with several sheets that I need to move into into new seperate workbooks. The sheet names change each week but the sheet code name remains the same (Sheets 4-8). The new workbooks will be saved in the same folder and take the name of the sheet.
I have found the following code from another thread which I think may be useful:
ActiveSheet.Move
With ActiveWorkbook
.SaveAs Filename:=ThisWorkbook.Path & "" & .Sheets(1).Name & ".xls"
.Close savechanges:=False
End With
Could you help me with how I can refer to the code name to select the right sheet in the code and then take the sheet name as the workbook name?
Thanks
I have a workbook with several sheets that I need to move into into new seperate workbooks. The sheet names change each week but the sheet code name remains the same (Sheets 4-8). The new workbooks will be saved in the same folder and take the name of the sheet.
I have found the following code from another thread which I think may be useful:
ActiveSheet.Move
With ActiveWorkbook
.SaveAs Filename:=ThisWorkbook.Path & "" & .Sheets(1).Name & ".xls"
.Close savechanges:=False
End With
Could you help me with how I can refer to the code name to select the right sheet in the code and then take the sheet name as the workbook name?
Thanks