Table of Contents

Method InsertMathText

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

InsertMathText(WordDocument, MathPosition, string)

Types text into a slot of an equation.

public static EquationEdit InsertMathText(this WordDocument document, MathPosition at, string text)

Parameters

document WordDocument

The document that holds the equation.

at MathPosition

Where the text goes; an offset inside a surrogate pair goes after the pair.

text string

The text, at most MaxMathTextLength characters; line breaks and tabs become spaces.

Returns

EquationEdit

The edit; After is just past the text. Empty text gives an empty edit.

Exceptions

ArgumentNullException

An argument is null.

ArgumentException

The equation is not in document.

ArgumentOutOfRangeException

The text is too long.

InvalidOperationException

The position no longer names a slot of the equation.