OpenXmlElement.AddNamespaceDeclaration(String, String) Method

Definition

Adds a namespace declaration to the current node.

public void AddNamespaceDeclaration (string prefix, string uri);
member this.AddNamespaceDeclaration : string * string -> unit
Public Sub AddNamespaceDeclaration (prefix As String, uri As String)

Parameters

prefix
String

The prefix.

uri
String

The uri.

Exceptions

Thrown if the prefix is already used in the current node.

Applies to