Skip to main content

Search OfficeIMO

Enter a topic, API type, or PowerShell command.

Documentation Search all OfficeIMO/
Class

ColumnComposer

OfficeIMO.Excel.ExcelReportBuilder

Namespace
OfficeIMO.Excel.ExcelReportBuilder
Assembly
OfficeIMO.Excel
Source revision
e163ccb36643 with working tree changes
Modifiers
sealed

Column-scoped composer used by ColumnComposer.Columns to write simple sections into a single column while keeping track of vertical position.

Inheritance

  • object
  • ColumnComposer

Usage

Explore 12 API references to this type

This type appears in these public API surfaces even when no hand-authored example is attached directly to the page.

Accepted by parameters 5

Methods

public ExcelTable AddTable<T>(IEnumerable<T?> items, string? title = null, Action<ObjectFlattenerOptions>? configure = null, ExcelTableStyle style = TableStyleMedium9, bool autoFilter = true, Action<ExcelTableVisualOptions>? visuals = null) #

Renders a table inside this column starting at the current row and returns the editable native table. This variant avoids freezing panes to prevent conflicts when multiple tables are placed per sheet.

Type Parameters

T

Parameters

items System.Collections.Generic.IEnumerable<T?> required
title string? = null optional
configure System.Action<OfficeIMO.Data.ObjectFlattenerOptions>? = null optional
style OfficeIMO.Excel.ExcelTableStyle = TableStyleMedium9 optional
autoFilter bool = true optional
visuals System.Action<OfficeIMO.Excel.ExcelTableVisualOptions>? = null optional

Returns

ExcelTable
public ColumnComposer BulletedList(IEnumerable<string> items) #

Writes a bullet for each item (• text) in this column.

Parameters

items System.Collections.Generic.IEnumerable<string> required
public ColumnComposer Columns(int count, Action<ColumnComposer[]> configure, int columnWidth = 3, int gutter = 1, ExcelReportOverflowMode overflow = Throw) #

Splits the current column region into horizontal sub-columns, rendering each via a nested ColumnComposer. Advances the parent column by the tallest child block and applies a spacer afterwards.

Parameters

count int required
Number of sub-columns to create.
configure System.Action<OfficeIMO.Excel.ExcelReportBuilder.ColumnComposer[]> required
Callback receiving the nested ColumnComposer instances.
columnWidth int = 3 optional
Width per sub-column in grid columns.
gutter int = 1 optional
Spacing between sub-columns in grid columns.
overflow OfficeIMO.Excel.ExcelReportOverflowMode = Throw optional
Specifies how content that exceeds the allocated width should be handled.
public ColumnComposer KeyValue(string key, object? value) #

Writes a two-column key/value row with styled key cell.

Parameters

key string required
value object? required
public ColumnComposer KeyValues(IEnumerable<ValueTuple<string, object?>> pairs) #

Writes multiple key/value rows in order.

Parameters

pairs System.Collections.Generic.IEnumerable<System.ValueTuple<string, object?>> required
public ColumnComposer Paragraph(string text) #

Writes a single paragraph cell and advances the row.

Parameters

text string required
public ColumnComposer Section(string text) #

Writes a section header cell using the current theme's section style.

Parameters

text string required
public ColumnComposer Spacer(int rows = 1) #

Adds vertical space.

Parameters

rows int = 1 optional
Number of rows to skip (minimum 1).

Properties

public int RowsUsed { get; } #

Total number of rows consumed by this column since it was created.

public int ColumnsUsed { get; } #

Total number of sheet columns used by this column content (>=1).