Table of Contents

Method AppendToList

Namespace
DocWright.Dom.Editing
Assembly
DocWright.Dom.dll

AppendToList(Paragraph, int, int)

Makes a paragraph part of an existing numbered or bulleted list.

The paragraph references the concrete NumberingInstance that is already defined; no abstract definition is cloned. Cloning one would start a second counter and the list would restart mid-document.

public static Paragraph AppendToList(this Paragraph paragraph, int numberingId, int level = 0)

Parameters

paragraph Paragraph

The paragraph.

numberingId int

The numbering instance id (w:numId).

level int

The zero-based list level (w:ilvl).

Returns

Paragraph

The same paragraph, so calls chain.

Exceptions

ArgumentNullException

paragraph is null.

ArgumentOutOfRangeException

level is outside 0-8.

InvalidDocumentException

The document defines no numbering instance with that id (DXP1003).