Click or drag to resize

OpenXmlElementGetAttribute Method

Gets an Open XML attribute with the specified tag name and namespace URI.

Namespace: DocumentFormat.OpenXml
Assembly: DocumentFormat.OpenXml (in DocumentFormat.OpenXml.dll) Version: 2.20.0+Branch.release-v2.20.0.Sha.a873d3fbff9bffe179fea62486da950adf5be65d.a873d3fbff9bffe179fea62486da950adf5be65d
Syntax
public OpenXmlAttribute GetAttribute(
	string localName,
	string namespaceUri
)

Parameters

localName  String
The tag name.
namespaceUri  String
The namespace URI.

Return Value

OpenXmlAttribute
Returns a clone of the OpenXmlAttribute with local name equal to "localName" and namespace URI equal to "namespaceUri".
Exceptions
ExceptionCondition
ArgumentOutOfRangeExceptionWhen the "localName" is empty.
KeyNotFoundExceptionWhen the element does not have the specified attribute.
See Also