- GrapeCity.Win.Spread.InputMan.CellType.GcNumberCellType ncell1 = new GrapeCity.Win.Spread.InputMan.CellType.GcNumberCellType();
- ncell1.AcceptsDecimal = GrapeCity.Win.Spread.InputMan.CellType.DecimalMode.Cut;
- ncell1.Fields.SetFields("0.00", "", "", "-", "");
- fpSpread1.ActiveSheet.Cells[1, 1].CellType = ncell1;
- fpSpread1.ActiveSheet.Cells[1, 1].Value = 0;
复制代码
- FarPoint.Win.Spread.CellType.PercentCellType prctcell = new FarPoint.Win.Spread.CellType.PercentCellType();
- prctcell.PercentSign = "%";
- prctcell.PositiveFormat = FarPoint.Win.Spread.CellType.PercentPositiveFormat.PercentAfter;
- prctcell.LeadingZero = FarPoint.Win.Spread.CellType.LeadingZero.Yes;
- prctcell.DecimalPlaces = 6;
- fpSpread1.ActiveSheet.Cells[2, 1].CellType = prctcell;
- fpSpread1.ActiveSheet.Cells[2, 1].Value = 0.000001;
复制代码 |