[]
Base class for Range and GrapeCity.Documents.Word.RangeBase.Body that allows manipulating content in a document.
public class RangeBase : ContentObjectCollection<ContentObject>, IContentList<ContentObject>, IReadOnlyList<ContentObject>, IReadOnlyCollection<ContentObject>, IEnumerable<ContentObject>, IEnumerable
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of bidirectional overrides included in this range.
public BidirectionalOverrideCollection BidirectionalOverrides { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of bookmarks included in this range.
public BookmarkCollection Bookmarks { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of canvas shapes included in this range.
public CanvasShapeCollection CanvasShapes { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of table cells included in this range.
public CellCollection Cells { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of comments included in this range.
public CommentCollection Comments { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of complex fields included in this range.
public ComplexFieldCollection ComplexFields { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of content controls included in this range.
public ContentControlCollection ContentControls { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the DocumentBase containing this range.
public DocumentBase Document { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of editable range objects included in this range.
public EditableRangeCollection EditableRanges { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the end marker of the range.
public Marker End { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of endnotes included in this range.
public EndnoteCollection Endnotes { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of footnotes included in this range.
public FootnoteCollection Footnotes { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of group shapes included in this range.
public GroupShapeCollection GroupShapes { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of hyperlinks included in this range.
public HyperlinkCollection Hyperlinks { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of ink shapes included in this range.
public InkShapeCollection InkShapes { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets a value indicating whether this range is alive and can be used.
If this range is a PersistentRange, this property always returns true.
If this range is a Range (created by a call to GetRange()) it can become unusable if its content is deleted. In that case this property will return false.
public bool IsAlive { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets a value indicating whether this range is empty (does not contain any formattable content).
public bool IsEmpty { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of OMathElement objects included in this range.
public OMathElementCollection OMathElements { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of OMathMatrixRow objects included in this range.
public OMathMatrixRowCollection OMathMatrixRows { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of OMathParagraph objects included in this range.
public OMathParagraphCollection OMathParagraphs { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of OMath objects included in this range.
public OMathCollection OMaths { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of OMathStruct objects included in this range.
public OMathStructCollection OMathStructs { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of paragraphs included in this range.
public ParagraphCollection Paragraphs { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of pictures included in this range.
public PictureCollection Pictures { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of table rows included in this range.
public RowCollection Rows { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of text runs included in this range.
public RunCollection Runs { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of sections included in this range.
public SectionCollection Sections { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of shapes included in this range.
public ShapeCollection Shapes { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of simple fields included in this range.
public SimpleFieldCollection SimpleFields { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the start marker of the range.
public Marker Start { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of tables included in this range.
public TableCollection Tables { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the text included in this range, as a string.
public string Text { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of text frames included in this range.
public TextFrameCollection TextFrames { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of texts included in this range.
public TextCollection Texts { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of unknown objects included in this range.
public UnknownContentCollection Unknowns { get; }
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Clears all content in this range, excluding bound markers.
public virtual void Clear()
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Clears formatting on content in this range.
Note that this method does not remove formatting applied indirectly via the content hierarchy.
public void ClearFormatting()
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Compares this range location with another range location.
public LocationRelation CompareLocationWith(RangeBase range)
range
RangeBaseThe range to compare this range with.
A LocationRelation value representing the result of the comparison.
Results returns compare that our current range applied on provided range
. So, for example, result Contains mean our range contains provided range.
Copies this range to another range.
public Range CopyTo(RangeBase to, InsertLocation insertLocation, FormattingCopyStrategy copyStrategy = FormattingCopyStrategy.Copy)
to
RangeBaseThe destination range.
insertLocation
InsertLocationThe target location relative to the destination range.
copyStrategy
FormattingCopyStrategyIndicates whether to preserve the source formatting.
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets the collection of all drawing objects (derived from ShapeBase) included in this range. Drawing objects include Picture, Shape, and unknow shape types.
public ContentObjectCollection<ShapeBase> GetDrawings()
The collection of all drawing objects in this range.
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Creates and returns a collection of content objects in the current range. The returned collection differs from enumerating on the current range itself in that it does not include objects that start before the current range's start and end after the current range's end.
public ContentObjectCollection<T> GetInnerCollection<T>() where T : ContentObject
The newly created ContentObjectCollection<T>.
T
The type of items in the collection.
See also remarks on RangeBase.
Creates and returns an instance of PersistentRange with bounds on the specified objects.
You should dispose the PersistentRange returned by this method when it is no longer needed. Failing to do so may lead to degraded performance.
public PersistentRange GetPersistentRange(ContentObject first, ContentObject last)
first
ContentObjectThe first content object to include in the range.
last
ContentObjectThe last content object to include in the range.
The newly created instance of PersistentRange.
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Creates and returns an instance of PersistentRange with bounds on the specified markers.
You should dispose the PersistentRange returned by this method when it is no longer needed. Failing to do so may lead to degraded performance.
public PersistentRange GetPersistentRange(Marker start, Marker end)
The newly created instance of PersistentRange.
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Inserts a built-in Office Math equation into the range.
public ContentObject[] InsertOMathEquation(OMathBuiltInEquation equation, InsertLocation location)
equation
OMathBuiltInEquationThe built-in equation to fill the OMath.
location
InsertLocationThe target InsertLocation for the insertion.
The array of inserted ContentObject objects.
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Moves this range to another range.
public Range MoveTo(RangeBase to, InsertLocation insertLocation, FormattingCopyStrategy copyStrategy = FormattingCopyStrategy.Copy)
to
RangeBaseThe destination range.
insertLocation
InsertLocationThe target location relative to the destination range.
copyStrategy
FormattingCopyStrategyIndicates whether to preserve the source formatting.
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range:
Gets string representation of the range.
public override string ToString()
String representation of the range.
A range's content is determined by its Start and End markers. Content objects that satisfy any of the following conditions are included in the range: