Hi,
Try this code-
Sub ExportToCSV_v2() Dim ws As Worksheet Set ws = Worksheets("export") ' Set list separator to semicolon Application.DecimalSeparator = "," Application.ThousandsSeparator = " " Application.UseSystemSeparators = False Application.ListSeparator = ";" ' Save the worksheet as CSV Dim fileName As String fileName = Left(ws.Parent.Name, 5) Dim currentDir As String currentDir = ThisWorkbook.Path ws.SaveAs fileName:=currentDir & "\" & fileName & ".csv", FileFormat:=xlCSV ' Reset list separator to default (comma) Application.UseSystemSeparators = True End Sub