Save Excel file with specific cell value by using VBA code
Help!! I am trying to finish a new tool to use in our shop and I have a couple of steps I can't figure out......
1) I would like to create a macro that will save a file using the contents of a specific cell (customers name) as the file name. I found this script that works, but I can't figure out how to execute the command!
VBA code: Save Excel file with specific cell value
Private Sub filename_cellvalue()
'Update 20141112
Dim Path As String
Dim filename As String
Path = "C:\Users\dt\Desktop\my information\"
filename = Range("A1")
ActiveWorkbook.SaveAs filename:=Path & filename & ".xls", FileFormat:=xlNormal
End Sub
and
2) I would like to record a macro that exports the .xlsm file into a .pdf, so I can send it to the customer in that format, not an excel file.
|