View Single Post
 
Old 01-04-2022, 01:56 PM
grandneos grandneos is offline Mac OS X Office 2016 for Mac
Novice
 
Join Date: Jan 2022
Posts: 1
grandneos is on a distinguished road
Default VBA Excel method Not working

I am looking to create a macro that allows me to save a new file with the file name as the one in cell J6. I keep getting a run time error as '1004': how do I fix this problem?Below is the code


Sub Macro20
Macro2 Macro
Dim ID As String
Dim Path As String

Path = "/Users/viniweichselbaumer/Documents/Server/Finance and Admin/Business App Development /"
ID = Range("]6"). Value & "xlsm"
Application.DisplayAlerts = False
ActiveWorkbook.SaveAs FileName: =Path & ID, FileFormat: =x|sm
Application.DisplayAlerts = True
ActiveWorkbook.Close
End Sub
Attached Files
File Type: pdf Screen Shot 2022-01-04 at 12.36.38 PM.png.pdf (181.6 KB, 5 views)
Reply With Quote