次のコードはテンプレートの列ヘッダにColumnHeaderCell、行にTextBoxCellを追加します。
Imports GrapeCity.Win.MultiRow Dim Template1 As Template = New Template() Dim ColumnHeaderSection1 As ColumnHeaderSection = New ColumnHeaderSection() Dim ColumnHeaderCell1 As ColumnHeaderCell = New ColumnHeaderCell() Dim TextBoxCell1 As TextBoxCell = New TextBoxCell() Template1.Width = TextBoxCell1.Size.Width Template1.Row.Cells.Add(TextBoxCell1) Template.Row.Height = TextBoxCell1.Size.Height ColumnHeaderSection1.Cells.Add(ColumnHeaderCell1) ColumnHeaderSection1.Height = ColumnHeaderCell1.Size.Height Template1.ColumnHeaders.Add(ColumnHeaderSection1) GcMultiRow1.Template = Template1 GcMultiRow1.RowCount = 10
using GrapeCity.Win.MultiRow; Template template1 = new Template(); ColumnHeaderSection columnHeaderSection1 = new ColumnHeaderSection(); ColumnHeaderCell columnHeaderCell1 = new ColumnHeaderCell(); TextBoxCell textBoxCell1 = new TextBoxCell(); template1.Width = textBoxCell1.Size.Width; template1.Row.Cells.Add(textBoxCell1); template1.Row.Height = textBoxCell1.Size.Height; columnHeaderSection1.Cells.Add(columnHeaderCell1); columnHeaderSection1.Height = columnHeaderCell1.Size.Height; template1.ColumnHeaders.Add(columnHeaderSection1); gcMultiRow1.Template = template1; gcMultiRow1.RowCount = 10;