Regarding the answer above, it is important to know that Application.DecimalSeparator
and Application.International(xlDecimalSeparator)
do not behave the same way:
Application.DecimalSeparator
will ALWAYS output the decimal separator chosen in Excel options even when Excel is told to use System Separators (from Windows regional settings)Application.International(xlDecimalSeparator)
will output whatever is the actual decimal separator used by Excel whether it comes from Windows settings (whenApplication.UseSystemSeparators = True
) or from Excel options (whenApplication.UseSystemSeparators = False
)
I therefore strongly recommend to always use Application.International(xlDecimalSeparator)
.