ExcelBanter

ExcelBanter (https://www.excelbanter.com/)
-   Excel Programming (https://www.excelbanter.com/excel-programming/)
-   -   how to save only one sheet as workbook (https://www.excelbanter.com/excel-programming/307299-how-save-only-one-sheet-workbook.html)

Kiknadze Lado

how to save only one sheet as workbook
 
Dear All,

I have workbook with sheets: sheet1, sheet2, sheet3.
I want to save this workbook in three workbooks. First workbook should have
only one sheet (sheet1), second workbook should have only one sheet (sheet2)
and third should have also one sheet (sheet3) and workbooks names I would
like to have sheet1, sheet2, sheet3 as well.
How I can do this manually and in VBA (if I have many sheets in essential
workbook)

Best wishes,
Lado



Kiknadze Lado

how to save only one sheet as workbook
 
Thank you,

This works fine.

Best,
Lado

"Norman Jones" wrote in message
...
Hi Lado,

Addressing the programming solution, try:

Sub Tester()
Dim WB As Workbook
Dim WS As Worksheet

Set WB = ActiveWorkbook

For Each WS In WB.Worksheets
WS.Copy
ActiveWorkbook.SaveAs WS.Name
Next WS

End Sub

This will save each sheet of the workbook as a new single-sheet workbook
bearing the name of the original sheet.


---
Regards,
Norman



"Kiknadze Lado" wrote in message
...
Dear All,

I have workbook with sheets: sheet1, sheet2, sheet3.
I want to save this workbook in three workbooks. First workbook should

have
only one sheet (sheet1), second workbook should have only one sheet

(sheet2)
and third should have also one sheet (sheet3) and workbooks names I

would
like to have sheet1, sheet2, sheet3 as well.
How I can do this manually and in VBA (if I have many sheets in

essential
workbook)

Best wishes,
Lado







Norman Jones

how to save only one sheet as workbook
 
Hi Lado,

Addressing the programming solution, try:

Sub Tester()
Dim WB As Workbook
Dim WS As Worksheet

Set WB = ActiveWorkbook

For Each WS In WB.Worksheets
WS.Copy
ActiveWorkbook.SaveAs WS.Name
Next WS

End Sub

This will save each sheet of the workbook as a new single-sheet workbook
bearing the name of the original sheet.


---
Regards,
Norman



"Kiknadze Lado" wrote in message
...
Dear All,

I have workbook with sheets: sheet1, sheet2, sheet3.
I want to save this workbook in three workbooks. First workbook should

have
only one sheet (sheet1), second workbook should have only one sheet

(sheet2)
and third should have also one sheet (sheet3) and workbooks names I would
like to have sheet1, sheet2, sheet3 as well.
How I can do this manually and in VBA (if I have many sheets in essential
workbook)

Best wishes,
Lado






All times are GMT +1. The time now is 05:53 PM.

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