Freigeben über


Border-Klasse

Border Properties.When the object is serialized out as xml, its qualified name is x:border.

Vererbungshierarchie

System.Object
  DocumentFormat.OpenXml.OpenXmlElement
    DocumentFormat.OpenXml.OpenXmlCompositeElement
      DocumentFormat.OpenXml.Spreadsheet.Border

Namespace:  DocumentFormat.OpenXml.Spreadsheet
Assembly:  DocumentFormat.OpenXml (in DocumentFormat.OpenXml.dll)

Syntax

'Declaration
<ChildElementInfoAttribute(GetType(LeftBorder))> _
<ChildElementInfoAttribute(GetType(HorizontalBorder))> _
<ChildElementInfoAttribute(GetType(VerticalBorder))> _
<ChildElementInfoAttribute(GetType(DiagonalBorder))> _
<ChildElementInfoAttribute(GetType(BottomBorder))> _
<ChildElementInfoAttribute(GetType(RightBorder))> _
<ChildElementInfoAttribute(GetType(TopBorder))> _
<ChildElementInfoAttribute(GetType(StartBorder), FileFormatVersions.Office2010)> _
<ChildElementInfoAttribute(GetType(EndBorder), FileFormatVersions.Office2010)> _
Public Class Border _
    Inherits OpenXmlCompositeElement
'Usage
Dim instance As Border
[ChildElementInfoAttribute(typeof(LeftBorder))]
[ChildElementInfoAttribute(typeof(HorizontalBorder))]
[ChildElementInfoAttribute(typeof(VerticalBorder))]
[ChildElementInfoAttribute(typeof(DiagonalBorder))]
[ChildElementInfoAttribute(typeof(BottomBorder))]
[ChildElementInfoAttribute(typeof(RightBorder))]
[ChildElementInfoAttribute(typeof(TopBorder))]
[ChildElementInfoAttribute(typeof(StartBorder), FileFormatVersions.Office2010)]
[ChildElementInfoAttribute(typeof(EndBorder), FileFormatVersions.Office2010)]
public class Border : OpenXmlCompositeElement

Hinweise

The following table lists the possible child types:

  • StartBorder <x:start>

  • EndBorder <x:end>

  • LeftBorder <x:left>

  • RightBorder <x:right>

  • TopBorder <x:top>

  • BottomBorder <x:bottom>

  • DiagonalBorder <x:diagonal>

  • VerticalBorder <x:vertical>

  • HorizontalBorder <x:horizontal>

[ISO/IEC 29500-1 1. Ausgabe]

18.8.4 border (Border)

Expresses a single set of cell border formats (left, right, top, bottom, diagonal). Color is optional. When missing, 'automatic' is implied.

Parent Elements

borders (§18.8.5); dxf (§18.8.14); ndxf (§18.11.1.4); odxf (§18.11.1.6)

Child Elements

Subclause

bottom (Bottom Border)

§18.8.6

diagonal (Diagonal)

§18.8.13

end (Trailing Edge Border)

§18.8.16

horizontal (Horizontal Inner Borders)

§18.8.25

start (Leading Edge Border)

§18.8.37

top (Top Border)

§18.8.43

vertical (Vertical Inner Border)

§18.8.44

Attributes

Description

diagonalDown (Diagonal Down)

A boolean value indicating if the cell's diagonal border includes a diagonal line, starting at the top left corner of the cell and moving down to the bottom right corner of the cell.

[Example:

This example shows a thin diagonal down line:

DocumentFormat.OpenXml.Spreadsheet.Border-image001

end example]

The possible values for this attribute are defined by the W3C XML Schema boolean datatype.

diagonalUp (Diagonal Up)

A boolean value indicating if the cell's diagonal border includes a diagonal line, starting at the bottom left corner of the cell and moving up to the top right corner of the cell.

[Example:

This example shows a thin diagonal up line:

DocumentFormat.OpenXml.Spreadsheet.Border-image002

end example]

The possible values for this attribute are defined by the W3C XML Schema boolean datatype.

outline (Outline)

A boolean value indicating if left, right, top, and bottom borders should be applied only to outside borders of a cell range.

The possible values for this attribute are defined by the W3C XML Schema boolean datatype.

[Note: The W3C XML Schema definition of this element's content model (CT_Border) is located in §A.2. end note]

© ISO/IEC29500: 2008. Die oben aufgeführten Textauszüge wurden von Microsoft (und/oder den Microsoft-Vendoren) von Englisch nach Deutsch übersetzt, und im Rahmen von ISO wird keinerlei Verantwortung für diese Übersetzungen übernommen.

Threadsicherheit

Alle öffentlichen static (Shared in Visual Basic) Member dieses Typs sind threadsicher. Bei Instanzmembern ist die Threadsicherheit nicht gewährleistet.

Siehe auch

Referenz

Border-Member

DocumentFormat.OpenXml.Spreadsheet-Namespace