Method InsertEquation
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
documentWordDocumentThe document.
atDocumentPositionWhere the equation goes.
equationOfficeMathA 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.