torourke17
New Member
- Joined
- Jan 12, 2018
- Messages
- 12
- Office Version
- 365
- 2019
- Platform
- Windows
I'm working with a code that saves a workbook in a specific location based on what's in a specific cell value. I would like it to copy the workbook, save it in a specific location based on a cell value, and then it will close, leaving me with my Master Workbook.
Here is the code I was working with:
Sub filename_cellvalue()
Dim Path As String
Dim filename As String
Path = "G:\abc\123"
filename = Range("C162")
ActiveWorkbook.SaveAs filename:=Path & filename & ".xlsm", FileFormat:=52
End Sub
Here is the code I was working with:
Sub filename_cellvalue()
Dim Path As String
Dim filename As String
Path = "G:\abc\123"
filename = Range("C162")
ActiveWorkbook.SaveAs filename:=Path & filename & ".xlsm", FileFormat:=52
End Sub