Lee Rabbit
New Member
- Joined
- Apr 30, 2020
- Messages
- 43
- Office Version
- 2010
- Platform
- Windows
Hi Guys,
I need a tweak on the code below. It does what I initially wanted but now I only want the contents of the duplicated sheets to show the values.
At present it is showing formula linked back to the original spreadsheet. I want to rid the new workbook of the formulas.
Please see my code below.
Regards and thanks in advance for your help.
Lee
I need a tweak on the code below. It does what I initially wanted but now I only want the contents of the duplicated sheets to show the values.
At present it is showing formula linked back to the original spreadsheet. I want to rid the new workbook of the formulas.
Please see my code below.
Regards and thanks in advance for your help.
Lee
VBA Code:
Sub Duplicate_Workbook()
ActiveWorkbook.Sheets(Array("INVOICE 1", "INVOICE 2", "INVOICE 3")).Copy
Application.DisplayAlerts = False
ActiveWorkbook.SaveAs Filename:="c:\PDF\test.xlsx", FileFormat:=xlOpenXMLWorkbook
Application.DisplayAlerts = True
ActiveWorkbook.Close
End Sub