FlexGrid for WinForms
Cell Ranges
Show AllShow All
Hide AllHide All

CellRange objects allow you to work on arbitrary groups of cells as a single unit. For example, the code below creates a CellRange object, clears the data in the range, and assigns it a custom style:

To write code in Visual Basic

To write code in C#

The CellRange object has a StyleNew property that retrieves the range style, if one exists, or creates a new one, assigns it to the range, and returns it. This property is convenient in situations where you don't need full-fledged control over formatting. For example, if all you want to do is give the range a red background, you can write:

To write code in Visual Basic

To write code in C#

See Also

 

 


Copyright © GrapeCity, inc. All rights reserved.

Product Support Forum |  Documentation Feedback