Hi,
I currently have a macro to delete a row if a certain value is 0 and then brings up the save as CSV to save as any required file name.
I was wondering if it was possible to advance this further by also saving it into a folder on the desktop and the file name being the date the macro was run.
This is the macro that currently works perfectly.
Sub ReduceRowsAndSave()
Dim strFileName As String, LR As Long
strFileName = Application.GetSaveAsFilename(filefilter:="Comma Seperated Values (*.csv), *.csv")
If strFileName = "False" Then Exit Sub
Sheets("RoyalMail").Copy
ActiveSheet.AutoFilterMode = False
Rows(1).AutoFilter
Rows(1).AutoFilter 5, 0
LR = Range("E" & Rows.Count).End(xlUp).Row
If LR > 1 Then Range("A2:A" & LR).EntireRow.Delete xlShiftUp
ActiveSheet.AutoFilterMode = False
ActiveWorkbook.SaveAs strFileName, xlCSV
ActiveWindow.Close False
End Sub
Any help would be much appreciated.
Thanks
James
Bookmarks