Table of Contents

Method InsertEquation

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

InsertEquation(WordDocument, DocumentPosition, OfficeMath)

Inserts an equation at a position of a paragraph.

public static EquationEdit InsertEquation(this WordDocument document, DocumentPosition at, OfficeMath equation)

Parameters

document WordDocument

The document.

at DocumentPosition

Where the equation goes.

equation OfficeMath

A new equation, in no document (OfficeMath(bool), FromLinearText(string, bool)).

Returns

EquationEdit

The edit; After is the end of the equation's first line.

Exceptions

ArgumentNullException

An argument is null.

ArgumentException

The position is not in document, or the equation is already placed or has no line.

InvalidOperationException

The position is inside a surrogate pair or a field's result.