OfficeIMO

API Reference

Class

TableBuilder (Word)

Namespace OfficeIMO.Word
Assembly OfficeIMO.Word
Modifiers static

Provides helper methods for constructing Wordprocessing tables from generic table representations.

Inheritance

  • Object
  • TableBuilder

Methods

public static Table Build(IEnumerable<IEnumerable<Action<TableCell>>> structure) #
Returns: Table

Builds a Table instance from the supplied structure. Each cell is represented by an action that populates a TableCell.

Parameters

structure System.Collections.Generic.IEnumerable{System.Collections.Generic.IEnumerable{System.Action{DocumentFormat.OpenXml.Wordprocessing.TableCell}}} requiredposition: 0
Table definition where the first dimension represents rows and the second dimension represents cells within a row.

Returns

Constructed Table.

public static IEnumerable<IReadOnlyList<WordTableCell>> Map(WordTable table) #
Returns: IEnumerable<IReadOnlyList<WordTableCell>>

Maps an existing WordTable to a simple matrix of cells. This is useful for consumers that need to iterate over table cells without dealing with the underlying OpenXML structure.

Parameters

table OfficeIMO.Word.WordTable requiredposition: 0
Table to map.

Returns

A matrix representing the table where each entry is a WordTableCell.