ComponentOne True DBGrid for .NET (2.0) Search HelpCentral 

Example 2 - Affecting Only Data Cells in the First Split

In this example, only the data cells of the first split are affected. This is because the split caption, column headers, and column footers inherit their fonts from the built-in styles Caption, Heading, and Footing, respectively.

The following code affects data cells only in the first split:

·      Visual Basic

Dim myfont As Font

myfont = New Font (Me.C1TrueDBGrid1.Splits(0).Style.Font, FontStyle.Bold)

Me.C1TrueDBGrid1.Splits(0).Style.Font = myfont

·      C#

Font myfont;

myfont = new Font (this.C1TrueDBGrid1.Splits[0].Style.Font, FontStyle.Bold);

this.C1TrueDBGrid1.Splits[0].Style.Font = myfont;

·      Delphi

var myfont: Font;

 

myfont := Font.Create(Self.C1TrueDBGrid1.Splits[0].Style.Font, FontStyle.Bold);

Self.C1TrueDBGrid1.Splits[0].Style.Font := myfont;

 


Send comments about this topic to ComponentOne.
Copyright © ComponentOne LLC. All rights reserved.