Ends the scope of the prefix-URI namespace mapping.
The reader calls this method after the corresponding endElement
method.
Sub endPrefixMapping(strPrefix As String)
If failed, the ContentHandler
raises a trappable error.
The following example shows how to use the endPrefixMapping
method to indicate that a namespace prefix has been ended or discontinued in the document.
Private Sub IVBSAXContentHandler_endPrefixMapping(strPrefix As String) Dim msg As String msg = "End prefix mapping." & vbCrLf & _ "strPrefix: " & strPrefix & vbCrLf Form1.TextBox1.Text = Form1.TextBox1.Text & msg End Sub
This event always occurs after the corresponding endElement
event, but the order of the endPrefixMapping
events is not otherwise guaranteed.
HRESULT endPrefixMapping( [in] const wchar_t * pwchPrefix, [in] int cchPrefix);
The information from this event is not necessary for normal namespace processing. The reader automatically replaces prefixes for element and attribute names when the "http://xml.org/sax/features/namespaces"
feature is set to True (the default).
There are cases, however, when applications need to use prefixes in character data or in attribute values and they cannot safely be expanded automatically. In these cases, the startPrefixMapping
and endPrefixMapping
methods can supply the information needed to expand prefixes.
There is no guarantee that the startPrefixMapping
and endPrefixMapping
events are properly nested relative to each other. All startPrefixMapping
events occur before the corresponding startElement
event, and all endPrefixMapping
events occur after the corresponding endElement
event, but their order is not otherwise guaranteed.
To view reference information for Visual Basic or C/C++ only, click the Language Filter button in the upper-left corner of the page.
endElement Method | startElement Method | startPrefixMapping Method
Applies to: ISAXContentHandler/IVBSAXContentHandler Interface