Spread Windows Forms 10.0 Product Documentation
SideButtons Property (GcNumberCellType)
Example 


Gets a collection of side buttons.
Syntax
'Declaration
 
Public Property SideButtons As SideButtonCollectionInfo
'Usage
 
Dim instance As GcNumberCellType
Dim value As SideButtonCollectionInfo
 
instance.SideButtons = value
 
value = instance.SideButtons
public SideButtonCollectionInfo SideButtons {get; set;}

Property Value

A SideButtonCollection value that indicates the collection.
Remarks
The SideButtons can be added or removed. They include the DropDownButton, SpinButton, SideButton, and SymbolButton.
Example
This example creates side buttons for increasing or decreasing the value.
GrapeCity.Win.Spread.InputMan.CellType.SideButtonInfo testbutton = new GrapeCity.Win.Spread.InputMan.CellType.SideButtonInfo();
testbutton.Behavior = GrapeCity.Win.Spread.InputMan.CellType.SideButtonBehavior.SpinDown;
testbutton.BackColor = Color.Red;
testbutton.UseVisualStyleBackColor = false;
GrapeCity.Win.Spread.InputMan.CellType.SideButtonInfo testbutton1 = new GrapeCity.Win.Spread.InputMan.CellType.SideButtonInfo();
testbutton1.BackColor = Color.Green;
testbutton1.UseVisualStyleBackColor = false;
testbutton1.Behavior = GrapeCity.Win.Spread.InputMan.CellType.SideButtonBehavior.SpinUp;
GrapeCity.Win.Spread.InputMan.CellType.GcNumberCellType ncell1 = new GrapeCity.Win.Spread.InputMan.CellType.GcNumberCellType();
//Clears other buttons including the calculator button
ncell1.SideButtons.Clear();
ncell1.SideButtons.Add(testbutton);
ncell1.SideButtons.Add(testbutton1);
ncell1.Spin.AllowSpin = true;
ncell1.Spin.IncrementValue = 1;           
ncell1.Spin.SpinMode = GrapeCity.Win.Spread.InputMan.CellType.NumberSpinMode.Value;          
fpSpread1.Sheets[0].Cells[1, 1].CellType = ncell1;
fpSpread1.ActiveSheet.Cells[1, 1].Value = 12.31;
Dim testbutton As New GrapeCity.Win.Spread.InputMan.CellType.SideButtonInfo()
testbutton.Behavior = GrapeCity.Win.Spread.InputMan.CellType.SideButtonBehavior.SpinDown
testbutton.BackColor = Color.Red
testbutton.UseVisualStyleBackColor = False
Dim testbutton1 As New GrapeCity.Win.Spread.InputMan.CellType.SideButtonInfo()
testbutton1.BackColor = Color.Green
testbutton1.UseVisualStyleBackColor = False
testbutton1.Behavior = GrapeCity.Win.Spread.InputMan.CellType.SideButtonBehavior.SpinUp
Dim ncell1 As New GrapeCity.Win.Spread.InputMan.CellType.GcNumberCellType()
'Clears other buttons including the calculator button
ncell1.SideButtons.Clear()
ncell1.SideButtons.Add(testbutton)
ncell1.SideButtons.Add(testbutton1)
ncell1.Spin.AllowSpin = True
ncell1.Spin.IncrementValue = 1
ncell1.Spin.SpinMode = GrapeCity.Win.Spread.InputMan.CellType.NumberSpinMode.Value
FpSpread1.Sheets(0).Cells(1, 1).CellType = ncell1
FpSpread1.ActiveSheet.Cells(1, 1).Value = 12.31
Requirements

Target Platforms: Windows 2000 Professional (SP4), Windows 2000 Server, Windows 2003 Server (SP1), Windows Server 2012 R2, Windows 2008, Windows XP (SP2), Windows Vista, Windows 7, Windows 8, Windows 8.1, Windows 10

See Also

Reference

GcNumberCellType Class
GcNumberCellType Members

 

 


Copyright © GrapeCity, inc. All rights reserved.