Contains the character position within the line where the error occurred.
lValue = oXMLDOMParseError.linepos
Long integer. The property is read-only.
The following VBScript example attempts to load an XML document. If it encounters a parse error, it displays the line and position within that line where the error occurred.
Dim xmlDoc Set xmlDoc = CreateObject("Msxml2.DOMDocument") xmlDoc.async = False xmlDoc.load("c:\books.xml") If xmlDoc.parseError.errorcode <> 0 Then MsgBox ("A parse error occurred on line " & xmlDoc.parseError.line _ & " at position " & xmlDoc.parseError.linepos) Else MsgBox xmlDoc.documentElement.xml End If
Applies To: XMLDOMParseError Object