So, this code works on ActiveSheet, names it and then saves it to a fixed path.
Problem is it omits file extension. Need it to use the same file extension as original file has.
Problem is it omits file extension. Need it to use the same file extension as original file has.
VBA Code:
Sub MySaveTabName()
With CreateObject("Scripting.FileSystemObject")
strExt = "." & .GetExtensionName(ActiveWorkbook.FullName)
ActiveSheet.Name = "ABC - " & Format(Now(), "MM.dd.yy")
MyName = ActiveSheet.Name
End With
Const csPath As String = "C:\Test\"
ActiveWorkbook.SaveAs Filename:=csPath & MyName & strExt
End Sub