Spread Windows Forms 9.0 Product Documentation
MaxMinBehavior Property (GcDateTimeCellType)
Example 


Gets or sets the behavior when the new input value is outside of GcDateTime.MinDate and GcDateTime.MaxDate.
Syntax
'Declaration
 
Public Property MaxMinBehavior As MaxMinBehavior
'Usage
 
Dim instance As GcDateTimeCellType
Dim value As MaxMinBehavior
 
instance.MaxMinBehavior = value
 
value = instance.MaxMinBehavior
public MaxMinBehavior MaxMinBehavior {get; set;}

Property Value

A GcDateTime.MaxMinBehavior enumeration value that indicates the behavior when the new input value is outside of GcDateTime.MinDate and GcDateTime.MaxDate.
The default is MaxMinBehavior.AdjustToMaxMin.
Exceptions
ExceptionDescription
System.ComponentModel.InvalidEnumArgumentExceptionThe value is not a valid GcDateTime.MaxMinBehavior item.
Example
This example uses the MaxMinBehavior property.
GrapeCity.Win.Spread.InputMan.CellType.GcDateTimeCellType datecell = new GrapeCity.Win.Spread.InputMan.CellType.GcDateTimeCellType();
datecell.MaxDate = new System.DateTime(9999, 12, 31);
datecell.MinDate = DateTime.Now;
datecell.MaxMinBehavior = GrapeCity.Win.Spread.InputMan.CellType.MaxMinBehavior.Clear;
fpSpread1.Sheets[0].Cells[0, 0].CellType = datecell;
Dim datecell As New GrapeCity.Win.Spread.InputMan.CellType.GcDateTimeCellType()
datecell.MaxDate = new System.DateTime(9999, 12, 31)
datecell.MinDate = DateTime.Now
datecell.MaxMinBehavior = GrapeCity.Win.Spread.InputMan.CellType.MaxMinBehavior.Clear
FpSpread1.Sheets(0).Cells(0, 0).CellType = datecell
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

GcDateTimeCellType Class
GcDateTimeCellType Members

 

 


Copyright © GrapeCity, inc. All rights reserved.