Export (0) Print
Expand All
This topic has not yet been rated - Rate this topic

Grid Class

Provides methods and properties that manage the major and minor grids of Axis objects.

System.Object
  System.Web.UI.DataVisualization.Charting.Grid
    System.Web.UI.DataVisualization.Charting.TickMark

Namespace:  System.Web.UI.DataVisualization.Charting
Assembly:  System.Web.DataVisualization (in System.Web.DataVisualization.dll)
public class Grid

The Grid type exposes the following members.

  NameDescription
Public methodGridInitializes a new instance of the Grid class.
Top
  NameDescription
Public propertyEnabledGets or sets a flag that determines whether major or minor grid lines are enabled.
Public propertyIntervalGets or sets the interval between major or minor grid lines.
Public propertyIntervalOffsetGets or sets the offset of grid lines.
Public propertyIntervalOffsetTypeGets or sets the interval offset type of major and minor grid lines.
Public propertyIntervalTypeGets or sets the interval type for major or minor grid lines.
Public propertyLineColorGets or sets the line color of a grid.
Public propertyLineDashStyleGets or sets the line style of a grid.
Public propertyLineWidthGets or sets the line width of major and minor grid lines.
Top
  NameDescription
Public methodEquals(Object)Determines whether the specified object is equal to the current object. (Inherited from Object.)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.)
Public methodGetHashCodeServes as the default hash function. (Inherited from Object.)
Public methodGetTypeGets the Type of the current instance. (Inherited from Object.)
Protected methodMemberwiseCloneCreates a shallow copy of the current Object. (Inherited from Object.)
Public methodToStringReturns a string that represents the current object. (Inherited from Object.)
Top

This class provides the functionality for the grids on the chart, and is exposed using the MajorGrid and MinorGrid properties of each Axis object.

Major grid lines by default do not have their Interval, IntervalOffset, IntervalType, and IntervalOffsetType properties set. When these properties for major grid lines are not set, the Chart control determines the appropriate values for grid lines automatically.

The axis and its minor grid lines by default have their Interval, IntervalOffset, IntervalType, and IntervalOffsetType properties set to Auto (0). If axis labels or minor grid lines are enabled and these properties are not modified, the Chart control automatically determines how often to draw the minor grid lines.

Axis grids:

  • Can be enabled or disabled.

  • Have a starting point that determines where they are first drawn.

  • Display lines that can be set for style, width and color.

  • Can have either automatic intervals, or intervals that are set manually.

.NET Framework

Supported in: 4.5.1, 4.5, 4

Windows Phone 8.1, Windows Phone 8, Windows 8.1, Windows Server 2012 R2, Windows 8, Windows Server 2012, Windows 7, Windows Vista SP2, Windows Server 2008 (Server Core Role not supported), Windows Server 2008 R2 (Server Core Role supported with SP1 or later; Itanium not supported)

The .NET Framework does not support all versions of every platform. For a list of the supported versions, see .NET Framework System Requirements.

Any public static (Shared in Visual Basic) members of this type are thread safe. Any instance members are not guaranteed to be thread safe.
Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.