You can format the values in the Unit Price column as currency values.
CS |
Copy Code |
---|---|
public MainPage() { InitializeComponent(); GcSpreadSheet1.Sheets[0].Rows.Count = GcSpreadSheet1.Sheets[0].GetLastDirtyRow(GrapeCity.Windows.SpreadSheet.Data.StorageType.Data) + 1; GcSpreadSheet1.Sheets[0].Columns.Count = GcSpreadSheet1.Sheets[0].GetLastDirtyColumn(GrapeCity.Windows.SpreadSheet.Data.StorageType.Data) + 1; GcSpreadSheet1.Sheets[0].Cells[1, 4, 77, 4].Formatter = new GrapeCity.Windows.SpreadSheet.Data.GeneralFormatter(GrapeCity.Windows.SpreadSheet.Data.FormatMode.StandardNumericMode, "c"); } |
VB.NET |
Copy Code |
---|---|
Public Sub New() InitializeComponent() GcSpreadSheet1.Sheets(0).Rows.Count = GcSpreadSheet1.Sheets(0).GetLastDirtyRow(GrapeCity.Windows.SpreadSheet.Data.StorageType.Data) + 1 GcSpreadSheet1.Sheets(0).Columns.Count = GcSpreadSheet1.Sheets(0).GetLastDirtyColumn(GrapeCity.Windows.SpreadSheet.Data.StorageType.Data) + 1 GcSpreadSheet1.Sheets(0).Cells(1, 4, 77, 4).Formatter = New GrapeCity.Windows.SpreadSheet.Data.GeneralFormatter(GrapeCity.Windows.SpreadSheet.Data.FormatMode.StandardNumericMode, "c") End Sub |
Save the project.
Run the project to see the currency values in the Unit Price column.
You have completed this tutorial.