Method InsertColumns
InsertColumns(WordDocument, TableCell, int, bool)
Inserts grid columns before or after a cell's columns, formatted like the cells beside them.
public static DocumentEdit InsertColumns(this WordDocument document, TableCell cell, int count, bool after)
Parameters
documentWordDocumentThe document that holds the cell.
cellTableCellThe cell to insert beside.
countintThe number of columns, at least 1.
afterboolTrue to insert after the cell, false before.
Returns
- DocumentEdit
The edit; After is the start of the new cell beside
cell.
Exceptions
- ArgumentNullException
documentorcellis null.- ArgumentException
The cell is not in a table of
document.- ArgumentOutOfRangeException
countis less than 1, or the table would have more than 63 columns.