Page tree

Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Migration of unmigrated content due to installation of a new plugin

...

Excerpt

This class is used to represent a region of the document that can be edited. This is the main class for manipulating the Word object model. Most elements of a Document inherit from the Element class.

Signature
C#
C#
<p> public class Element
Element</p>
Signature
vb.net
vb.net
Public<p>Public Class Element
Element</p>
Remarks

You cannot create a new Element object by using the new keyword. There are various properties

The following sample demonstrates getting an Element object by retrieving a section's header:

...

Name

Description

Children

Excerpt Include
WW8:Element.ChildrenWW8:
Element.Children
nopaneltrue

ElementType

Excerpt Include
WW8:Element.ElementTypeWW8:
Element.ElementType
nopaneltrue

Length

Excerpt Include
WW8:Element.LengthWW8:
Element.Length
nopaneltrue

Start

Excerpt Include
WW8:Element.StartWW8:
Element.Start
nopaneltrue

Text

Excerpt Include
WW8:Element.TextWW8:
Element.Text
nopaneltrue
Methods

Name

Description

CreateBookmark(String)

Excerpt Include
WW8:Element.CreateBookmark(String)WW8:
Element.CreateBookmark(String)
nopaneltrue

CreateSectionAfter()

Excerpt Include
WW8:Element.CreateSectionAfter()WW8:
Element.CreateSectionAfter()
nopaneltrue

CreateSectionBefore()

Excerpt Include
WW8:Element.CreateSectionBefore()WW8:
Element.CreateSectionBefore()
nopaneltrue

DeleteElement()

Excerpt Include
WW8:Element.DeleteElement()WW8:
Element.DeleteElement()
nopaneltrue

GetElements(Element.Type)

Excerpt Include
WW8:Element.GetElements(Element.Type)WW8:
Element.GetElements(Element.Type)
nopaneltrue

GetPosition(Int32)

Excerpt Include
WW8:Element.GetPosition(Int32)WW8:
Element.GetPosition(Int32)
nopaneltrue

ImportData(Object()())

Excerpt Include
WW8:Element.ImportData(Object()())WW8:
Element.ImportData(Object()())
nopaneltrue

ImportData(Object()(), String(), DataImportProperties)

Excerpt Include
WW8:Element.ImportData(Object()(), String(), DataImportProperties)WW8:
Element.ImportData(Object()(), String(), DataImportProperties)
nopaneltrue

ImportData(System.Data.DataTable)

Excerpt Include
WW8:Element.ImportData(System.Data.DataTable)WW8:
Element.ImportData(System.Data.DataTable)
nopaneltrue

ImportData(System.Data.DataTable, DataImportProperties)

Excerpt Include
WW8:Element.ImportData(System.Data.DataTable, DataImportProperties)WW8:
Element.ImportData(System.Data.DataTable, DataImportProperties)
nopaneltrue

ImportData(System.Data.DataView)

Excerpt Include
WW8:Element.ImportData(System.Data.DataView)WW8:
Element.ImportData(System.Data.DataView)
nopaneltrue

ImportData(System.Data.DataView, DataImportProperties)

Excerpt Include
WW8:Element.ImportData(System.Data.DataView, DataImportProperties)WW8:
Element.ImportData(System.Data.DataView, DataImportProperties)
nopaneltrue

ImportData(Object(,))

Excerpt Include
WW8:Element.ImportData(Object(,))WW8:
Element.ImportData(Object(,))
nopaneltrue

ImportData(Object(,), String(), DataImportProperties)

Excerpt Include
WW8:Element.ImportData(Object(,), String(), DataImportProperties)WW8:
Element.ImportData(Object(,), String(), DataImportProperties)
nopaneltrue

ImportData(System.Data.IDataReader)

Excerpt Include
WW8:Element.ImportData(System.Data.IDataReader)WW8:
Element.ImportData(System.Data.IDataReader)
nopaneltrue

ImportData(System.Data.IDataReader, DataImportProperties)

Excerpt Include
WW8:Element.ImportData(System.Data.IDataReader, DataImportProperties)WW8:
Element.ImportData(System.Data.IDataReader, DataImportProperties)
nopaneltrue

InsertAfter(Element)

Excerpt Include
WW8:Element.InsertAfter(Element)WW8:
Element.InsertAfter(Element)
nopaneltrue

InsertBefore(Element)

Excerpt Include
WW8:Element.InsertBefore(Element)WW8:
Element.InsertBefore(Element)
nopaneltrue

InsertBreakAfter(Element.BreakType)

Excerpt Include
WW8:Element.InsertBreakAfter(Element.BreakType)WW8:
Element.InsertBreakAfter(Element.BreakType)
nopaneltrue

InsertBreakBefore(Element.BreakType)

Excerpt Include
WW8:Element.InsertBreakBefore(Element.BreakType)WW8:
Element.InsertBreakBefore(Element.BreakType)
nopaneltrue

InsertHyperlinkAfter(String, String)

Excerpt Include
WW8:Element.InsertHyperlinkAfter(String, String)WW8:
Element.InsertHyperlinkAfter(String, String)
nopaneltrue

InsertHyperlinkBefore(String, String)

Excerpt Include
WW8:Element.InsertHyperlinkBefore(String, String)WW8:
Element.InsertHyperlinkBefore(String, String)
nopaneltrue

InsertImageAfter(System.IO.Stream)

Excerpt Include
WW8:Element.InsertImageAfter(System.IO.Stream)WW8:
Element.InsertImageAfter(System.IO.Stream)
nopaneltrue

InsertImageAfter(String)

Excerpt Include
WW8:Element.InsertImageAfter(String)WW8:
Element.InsertImageAfter(String)
nopaneltrue

InsertImageBefore(String)

Excerpt Include
WW8:Element.InsertImageBefore(String)WW8:
Element.InsertImageBefore(String)
nopaneltrue

InsertImageBefore(System.IO.Stream)

Excerpt Include
WW8:Element.InsertImageBefore(System.IO.Stream)WW8:
Element.InsertImageBefore(System.IO.Stream)
nopaneltrue

InsertListAfter(Boolean)

Excerpt Include
WW8:Element.InsertListAfter(Boolean)WW8:
Element.InsertListAfter(Boolean)
nopaneltrue

InsertListBefore(Boolean)

Excerpt Include
WW8:Element.InsertListBefore(Boolean)WW8:
Element.InsertListBefore(Boolean)
nopaneltrue

InsertMergeFieldAfter(String, String)

Excerpt Include
WW8:Element.InsertMergeFieldAfter(String, String)WW8:
Element.InsertMergeFieldAfter(String, String)
nopaneltrue

InsertMergeFieldBefore(String, String)

Excerpt Include
WW8:Element.InsertMergeFieldBefore(String, String)WW8:
Element.InsertMergeFieldBefore(String, String)
nopaneltrue

InsertParagraphAfter(NamedStyle)

Excerpt Include
WW8:Element.InsertParagraphAfter(NamedStyle)WW8:
Element.InsertParagraphAfter(NamedStyle)
nopaneltrue

InsertParagraphAfter(NamedStyle, ParagraphFormatting)

Excerpt Include
WW8:Element.InsertParagraphAfter(NamedStyle, ParagraphFormatting)WW8:
Element.InsertParagraphAfter(NamedStyle, ParagraphFormatting)
nopaneltrue

InsertParagraphBefore(NamedStyle)

Excerpt Include
WW8:Element.InsertParagraphBefore(NamedStyle)WW8:
Element.InsertParagraphBefore(NamedStyle)
nopaneltrue

InsertParagraphBefore(NamedStyle, ParagraphFormatting)

Excerpt Include
WW8:Element.InsertParagraphBefore(NamedStyle, ParagraphFormatting)WW8:
Element.InsertParagraphBefore(NamedStyle, ParagraphFormatting)
nopaneltrue

InsertTableAfter(Int32, Int32)

Excerpt Include
WW8:Element.InsertTableAfter(Int32, Int32)WW8:
Element.InsertTableAfter(Int32, Int32)
nopaneltrue

InsertTableAfter(Int32, Int32, TableFormatting)

Excerpt Include
WW8:Element.InsertTableAfter(Int32, Int32, TableFormatting)WW8:
Element.InsertTableAfter(Int32, Int32, TableFormatting)
nopaneltrue

InsertTableBefore(Int32, Int32)

Excerpt Include
WW8:Element.InsertTableBefore(Int32, Int32)WW8:
Element.InsertTableBefore(Int32, Int32)
nopaneltrue

InsertTableBefore(Int32, Int32, TableFormatting)

Excerpt Include
WW8:Element.InsertTableBefore(Int32, Int32, TableFormatting)WW8:
Element.InsertTableBefore(Int32, Int32, TableFormatting)
nopaneltrue

InsertTextAfter(String, Boolean)

Excerpt Include
WW8:Element.InsertTextAfter(String, Boolean)WW8:
Element.InsertTextAfter(String, Boolean)
nopaneltrue

InsertTextAfter(String, Font)

Excerpt Include
WW8:Element.InsertTextAfter(String, Font)WW8:
Element.InsertTextAfter(String, Font)
nopaneltrue

InsertTextBefore(String, Boolean)

Excerpt Include
WW8:Element.InsertTextBefore(String, Boolean)WW8:
Element.InsertTextBefore(String, Boolean)
nopaneltrue

InsertTextBefore(String, Font)

Excerpt Include
WW8:Element.InsertTextBefore(String, Font)WW8:
Element.InsertTextBefore(String, Font)
nopaneltrue

Search(String)

Excerpt Include
WW8:Element.Search(String)WW8:
Element.Search(String)
nopaneltrue

SearchAndReplace(String, String)

Excerpt Include
WW8:Element.SearchAndReplace(String, String)WW8:
Element.SearchAndReplace(String, String)
nopaneltrue

SubElement(Int32, Int32)

Excerpt Include
WW8:Element.SubElement(Int32, Int32)WW8:
Element.SubElement(Int32, Int32)
nopaneltrue

...

Overload

Description

ImportData(Microsoft.SharePoint.SPList)

Excerpt Include
WW8:SharePointIntegration.ImportData(Element, Microsoft.SharePoint.SPList)WW8:
SharePointIntegration.ImportData(Element, Microsoft.SharePoint.SPList)
nopaneltrue

ImportData(Microsoft.SharePoint.SPView, Microsoft.SharePoint.SPList, DataImportProperties)

Excerpt Include
WW8:SharePointIntegration.ImportData(Element, Microsoft.SharePoint.SPView, Microsoft.SharePoint.SPList, DataImportProperties)WW8:
SharePointIntegration.ImportData(Element, Microsoft.SharePoint.SPView, Microsoft.SharePoint.SPList, DataImportProperties)
nopaneltrue

...

Name

Description

BreakType

Excerpt Include
WW8:Element.BreakTypeWW8:
Element.BreakType
nopaneltrue

Type

Excerpt Include
WW8:Element.TypeWW8:
Element.Type
nopaneltrue