Share via


Highlight.Val Property

Definition

Highlighting Color

Represents the following attribute in the schema: w:val

[DocumentFormat.OpenXml.SchemaAttr(23, "val")]
public DocumentFormat.OpenXml.EnumValue<DocumentFormat.OpenXml.Wordprocessing.HighlightColorValues> Val { get; set; }
public DocumentFormat.OpenXml.EnumValue<DocumentFormat.OpenXml.Wordprocessing.HighlightColorValues> Val { get; set; }
[DocumentFormat.OpenXml.SchemaAttr(23, "val")]
public DocumentFormat.OpenXml.EnumValue<DocumentFormat.OpenXml.Wordprocessing.HighlightColorValues>? Val { get; set; }
[DocumentFormat.OpenXml.SchemaAttr("w:val")]
public DocumentFormat.OpenXml.EnumValue<DocumentFormat.OpenXml.Wordprocessing.HighlightColorValues>? Val { get; set; }
public DocumentFormat.OpenXml.EnumValue<DocumentFormat.OpenXml.Wordprocessing.HighlightColorValues>? Val { get; set; }
member this.Val : DocumentFormat.OpenXml.EnumValue<DocumentFormat.OpenXml.Wordprocessing.HighlightColorValues> with get, set
[<DocumentFormat.OpenXml.SchemaAttr(23, "val")>]
member this.Val : DocumentFormat.OpenXml.EnumValue<DocumentFormat.OpenXml.Wordprocessing.HighlightColorValues> with get, set
[<DocumentFormat.OpenXml.SchemaAttr("w:val")>]
member this.Val : DocumentFormat.OpenXml.EnumValue<DocumentFormat.OpenXml.Wordprocessing.HighlightColorValues> with get, set
Public Property Val As EnumValue(Of HighlightColorValues)

Property Value

Returns EnumValue<T>.

Attributes

Remarks

The following information from the ECMA International Standard ECMA-376 can be useful when working with this class.

Specifies the color of the text highlighting which shall be applied to the contents of this run.

Consider a text run which shall be displayed with colored text highlighting. This highlighting would be specified using the following WordprocessingML:

<w:rPr>  
  <w:highlight w:val="red" />  
</w:rPr>  

The resulting text highlighting would be red, as this is the color specified by the val attribute.

The possible values for this attribute are defined by the ST_HighlightColor simple type.

Applies to