WorkbookSettings.NumberDecimalSeparator
WorkbookSettings.NumberDecimalSeparator property
Gets or sets the decimal separator for formatting/parsing numeric values. Default is the decimal separator of current Region.
public char NumberDecimalSeparator { get; set; }
Examples
// Called: wb.Settings.NumberDecimalSeparator = ',';
public void WorkbookSettings_Property_NumberDecimalSeparator()
{
Workbook wb = new Workbook();
wb.Settings.Region = CountryCode.USA;
wb.Settings.NumberDecimalSeparator = ',';
wb.Settings.NumberGroupSeparator = '.';
Style style = wb.CreateStyle();
style.Custom = "#,##0.00";
Cell cell = wb.Worksheets[0].Cells[0, 0];
cell.PutValue(12345.6798);
cell.SetStyle(style);
Assert.AreEqual("12.345,68", cell.StringValue, "12345.6798");
}
See Also
- class WorkbookSettings
- namespace Aspose.Cells
- assembly Aspose.Cells