Sub macro1()
Dim wb As Workbook
Dim FileOpen
Application.DisplayAlerts = False
Set wb = ThisWorkbook
Workbooks.Add
wb.Sheets("Sheet1").UsedRange.Copy Sheets("Sheet1").Range("A1")
ChDir "C:\Macro\Tests"
ActiveWorkbook.SaveAs Filename:="C:\Macro\Tests\TigerX.csv", _
FileFormat:=xlCSV, CreateBackup:=False
ActiveWorkbook.Close False
Application.DisplayAlerts = True
End Sub
I have the above which copies what I want, opens a new workbook and saves the new workbook as TigerX.csv but I need the X to change based on what is already in the folder. If the folder already has Tiger1.csv and Tiger2.csv I need this file to be saved as Tiger3.csv
Bookmarks