Spread Windows Forms 12.0 Product Documentation
SpinDecimalIncrement Property (PercentCellType)
Example 


FarPoint.Win.Spread Assembly > FarPoint.Win.Spread.CellType Namespace > PercentCellType Class : SpinDecimalIncrement Property
Gets or sets the amount by which the value increments when using the spin buttons and the cursor is in the decimal portion.
Syntax
'Declaration
 
Public Property SpinDecimalIncrement As Single
'Usage
 
Dim instance As PercentCellType
Dim value As Single
 
instance.SpinDecimalIncrement = value
 
value = instance.SpinDecimalIncrement
public float SpinDecimalIncrement {get; set;}

Property Value

Floating-point number representing the increment
Remarks

This increment applies when the cursor is to the right of the decimal separator but the value is not limited to numbers less than 1.

Example
This example creates a percent-formatted numeric cell and sets the various formatting properties.
FarPoint.Win.Spread.CellType.PercentCellType prctcell = new FarPoint.Win.Spread.CellType.PercentCellType();
prctcell.DecimalPlaces = 3;
prctcell.DecimalSeparator = ",";
prctcell.FixedPoint = true;
prctcell.LeadingZero = FarPoint.Win.Spread.CellType.LeadingZero.UseRegional;
prctcell.MaximumValue = 50000.0;
prctcell.MinimumValue = -1000.0;
prctcell.NegativeFormat = FarPoint.Win.Spread.CellType.PercentNegativeFormat.PercentAfterWithSpace;
prctcell.NegativeRed = true;
prctcell.PercentSign = "%";
prctcell.PositiveFormat = FarPoint.Win.Spread.CellType.PercentPositiveFormat.PercentAfter;
prctcell.Separator = "/";
prctcell.ShowSeparator = true;
prctcell.SpinButton = true;
prctcell.SpinDecimalIncrement = 10;
prctcell.SpinIntegerIncrement = 5;
prctcell.SpinWrap = true;
fpSpread1.ActiveSheet.Cells[0, 0].CellType = prctcell;
fpSpread1.ActiveSheet.Cells[0, 0].Value = -443.0908;
Dim prctcell As New FarPoint.Win.Spread.CellType.PercentCellType()
prctcell.DecimalPlaces = 3
prctcell.DecimalSeparator = ","
prctcell.FixedPoint = True
prctcell.LeadingZero = FarPoint.Win.Spread.CellType.LeadingZero.UseRegional
prctcell.MaximumValue = 50000.0
prctcell.MinimumValue = -1000.0
prctcell.NegativeFormat = FarPoint.Win.Spread.CellType.PercentNegativeFormat.PercentAfterWithSpace
prctcell.NegativeRed = True
prctcell.PercentSign = "%"
prctcell.PositiveFormat = FarPoint.Win.Spread.CellType.PercentPositiveFormat.PercentAfter
prctcell.Separator = "/"
prctcell.ShowSeparator = True
prctcell.SpinButton = True
prctcell.SpinDecimalIncrement = 10
prctcell.SpinIntegerIncrement = 5
prctcell.SpinWrap = True
FpSpread1.ActiveSheet.Cells(0, 0).CellType = prctcell
FpSpread1.ActiveSheet.Cells(0, 0).Value = -443.9098
See Also

Reference

PercentCellType Class
PercentCellType Members

User-Task Documentation

Displaying Spin Buttons