Type | Description | |||
String | A string expression that indicates a CRD string that layouts the column's header. The Index elements in the CRD strings indicates the index of the column being displayed. The Caption elements in the CRD string support built-in HTML format. |
The following screen shot shows the control/list's header on 4 different levels, the same as displayed in the chart's area:
The following VB sample arranges the columns as in the above screen shot ( the sample hides the columns and add instead two new columns { Personal Info, General Info }, where the layout is displayed.
With G2antt1 .BeginUpdate Dim c As EXG2ANTTLibCtl.Column For Each c In .Columns c.Visible = False Next With .Columns.Add("Personal Info") .AllowSort = False .AllowDragging = False .Width = 196 .FormatLevel = "18;17/(14:54,(2/1/3))" End With With .Columns.Add("General Info") .AllowSort = False .AllowDragging = False .Width = 382 .FormatLevel = "18;18/((7/18;4):128,((((12/10/11),(5/6/9)),15)))" End With .EndUpdate End With
Before running the sample the control's header bar looks like follows:
After running the sample the control's header bar looks like follows:
The following C++ sample arranges the columns as in the above screen shot ( the sample hides the columns and add instead two new columns { Personal Info, General Info }, where the layout is displayed.
m_g2antt.BeginUpdate(); CColumns cols = m_g2antt.GetColumns(); long nCount = cols.GetCount(); for ( long i = 0; i < nCount; i++ ) cols.GetItem( COleVariant(i) ).SetVisible( FALSE ); CColumn col1( V_DISPATCH( &cols.Add( "Personal Info" ) ) ); col1.SetAllowSort( FALSE ); col1.SetAllowDragging( FALSE ); col1.SetWidth( 196 ); col1.SetFormatLevel( "18;18/(15:54,(2/1/4))" ); CColumn col2( V_DISPATCH( &cols.Add( "General Info" ) ) ); col2.SetAllowSort( FALSE ); col2.SetAllowDragging( FALSE ); col2.SetWidth( 512 ); col2.SetFormatLevel( "18;19/((8/18;5):128,((((13/11/12),(6/7/10)),16)))" ); m_g2antt.EndUpdate();
The following VB.NET sample arranges the columns as in the above screen shot ( the sample hides the columns and add instead two new columns { Personal Info, General Info }, where the layout is displayed.
With AxG2antt1 .BeginUpdate() Dim c As EXG2ANTTLib.Column For Each c In .Columns c.Visible = False Next With .Columns.Add("Personal Info") .AllowSort = False .AllowDragging = False .Width = 196 .FormatLevel = "18;18/(15:54,(2/1/4))" .Def(EXG2ANTTLib.DefColumnEnum.exCellFormatLevel) = "15:54,(2/1/4)" End With With .Columns.Add("General Info") .AllowSort = False .AllowDragging = False .Width = 512 .FormatLevel = "18;19/((8/18;5):128,((((13/11/12),(6/7/10)),16)))" .Def(EXG2ANTTLib.DefColumnEnum.exCellFormatLevel) = "(8/18;5):128,((((13/11/12),(6/7/10)),16))" End With .EndUpdate() End With
The following C# sample arranges the columns as in the above screen shot ( the sample hides the columns and add instead two new columns { Personal Info, General Info }, where the layout is displayed.
axG2antt1.BeginUpdate(); foreach( EXG2ANTTLib.Column c in axG2antt1.Columns) c.Visible = false; EXG2ANTTLib.Column c1 = axG2antt1.Columns.Add("Personal Info") as EXG2ANTTLib.Column; c1.AllowSort = false; c1.AllowDragging = false; c1.Width = 196; c1.FormatLevel = "18;18/(15:54,(2/1/4))"; c1.set_Def(EXG2ANTTLib.DefColumnEnum.exCellFormatLevel,"15:54,(2/1/4)"); EXG2ANTTLib.Column c2 = axG2antt1.Columns.Add("General Info") as EXG2ANTTLib.Column; c2.AllowSort = false; c2.AllowDragging = false; c2.Width = 512; c2.FormatLevel = "18;19/((8/18;5):128,((((13/11/12),(6/7/10)),16)))"; c2.set_Def(EXG2ANTTLib.DefColumnEnum.exCellFormatLevel,"(8/18;5):128,((((13/11/12),(6/7/10)),16))"); axG2antt1.EndUpdate();
The following VFP sample arranges the columns as in the above screen shot ( the sample hides the columns and add instead two new columns { Personal Info, General Info }, where the layout is displayed.
with thisform.G2antt1 .BeginUpdate() with .Columns for i = 0 to .Count - 1 .Item(i).Visible = .f. next with .Add("Personal Info") .AllowSort = .f. .AllowDragging = .f. .Width = 196 .FormatLevel = "18;18/(15:54,(2/1/4))" .Def(32) = "15:54,(2/1/4)" endwith with .Add("General Info") .AllowSort = .f. .AllowDragging = .f. .Width = 512 .FormatLevel = "18;19/((8/18;5):128,((((13/11/12),(6/7/10)),16)))" .Def(32) = "(8/18;5):128,((((13/11/12),(6/7/10)),16))" endwith endwith .EndUpdate() endwith