Home |
Search |
Today's Posts |
|
#1
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
I have a workbook which contains about 15 worksheets. I update the data for
the workbook and now need to save the individual sheets as separate workbooks using the sheet names as the file name. How do I loop through each worksheet and save them as separate workbooks using the sheet 'tab' names as the file names? Sub SaveSheet() ActiveSheet.Copy ActiveWorkbook.SaveAs "C:\Data\AMReports\" & ActiveSheet.Name & ".xls" ActiveWorkbook.Close SaveChanges:=False End Sub Thanks - -TB- - |
#2
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
See this page tom
http://www.rondebruin.nl/copy6.htm -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "TOMB" wrote in message ... I have a workbook which contains about 15 worksheets. I update the data for the workbook and now need to save the individual sheets as separate workbooks using the sheet names as the file name. How do I loop through each worksheet and save them as separate workbooks using the sheet 'tab' names as the file names? Sub SaveSheet() ActiveSheet.Copy ActiveWorkbook.SaveAs "C:\Data\AMReports\" & ActiveSheet.Name & ".xls" ActiveWorkbook.Close SaveChanges:=False End Sub Thanks - -TB- - |
#3
![]()
Posted to microsoft.public.excel.programming
|
|||
|
|||
![]()
Thanks Ron (and Colby). I used adjusted the code just a bit and it worked as
advertised! Thanks again - -TB - - "Ron de Bruin" wrote: See this page tom http://www.rondebruin.nl/copy6.htm -- Regards Ron de Bruin http://www.rondebruin.nl/tips.htm "TOMB" wrote in message ... I have a workbook which contains about 15 worksheets. I update the data for the workbook and now need to save the individual sheets as separate workbooks using the sheet names as the file name. How do I loop through each worksheet and save them as separate workbooks using the sheet 'tab' names as the file names? Sub SaveSheet() ActiveSheet.Copy ActiveWorkbook.SaveAs "C:\Data\AMReports\" & ActiveSheet.Name & ".xls" ActiveWorkbook.Close SaveChanges:=False End Sub Thanks - -TB- - |
Reply |
Thread Tools | Search this Thread |
Display Modes | |
|
|
![]() |
||||
Thread | Forum | |||
Check Worksheet When Workbook Is Saved | Excel Programming | |||
Save column J of WorkBook when WorkBook is not saved. | Excel Programming | |||
can I hyperlink to a worksheet tab in workbook saved as html? | Excel Discussion (Misc queries) | |||
How can I see a copy of a saved workbook before I saved it again? | Excel Worksheet Functions | |||
When saving workbook only the first worksheet gets saved. | Excel Worksheet Functions |