Sub ExportSheet()
Application.ScreenUpdating = False
Application.DisplayAlerts = False
Dim Folder As String
Dim locationname As String
Dim Response, pw
Dim NewLogRow As Long
Dim formula As String
Dim NameValue As String
Dim FinalName As String
Dim XXX As String
XXX = Format(Date, "[$-409]ddmmmyyyy;@")
locationname = Sheets("Budget").Range("A3").Value
Folder = "C:\Users\tphythian\Documents\Cost Tracking Exports"
Worksheets("Budget").Visible = True
ThisWorkbook.Worksheets("Budget").Copy
With ActiveSheet.UsedRange
.Value = .Value
End With
With ActiveWorkbook
.SaveAs Folder & "\" & locationname & " - " & XXX & " - Export" & ".xlsx"
.Close
End With
MsgBox "Sheet has been exported and saved in " & "Cost Tracking Exports" & " folder!"
Application.ScreenUpdating = True
Application.DisplayAlerts = True
End Sub