getLocalName Method

 

Finds an attribute's local name by index. For "xmlns", this value is empty.

Visual Basic Implementation Syntax

Function getLocalName(ByVal nIndex As Long) As String  

Visual Basic Usage Syntax

StrVal = oIVBSAXAttributes.getLocalName
(nIndex)  

Parameters

nIndex
The attribute's index value.

Return Values

If failed, raises a trappable error.

C/C++ Syntax

HRESULT getLocalName(  
   [in] int nIndex,   
   [out] const wchar_t ** ppwchLocalName,   
   [out] int * pcchLocalName);  

Parameters

nIndex[in]
The attribute's index value.

ppwchLocalName[out]
The attribute's local name. ppwchLocalName should not be modified or deleted, because this can cause undefined behavior in the SAX parser. If you want to preserve the value that was returned in ppwchLocalName, you should make a deep copy.

pcchLocalName[out]
The length of the local name string.

Return Values

S_OK
The value returned if the local name is returned successfully.

E_FAIL
The value returned if an internal error occurs.

E_INVALIDARG
The value returned if the local name cannot be found.

Versioning

Implemented in: MSXML 3.0 and later

Applies to

ISAXAttributes Interface

See Also

getLength Method (C-C++)
length Property (Visual Basic)