HRESULT Exists([in] BSTR Name, [in] BSTR Namespace, [out, retval] VARIANT_BOOL * Exists);
This allows you to check to see if a particular attribute exists in the element being de-serialized.
returns VARIANT_TRUE if there is an attribute with a matching name and namespace URI, otherwise returns VARIANT_FALSE
Option Explicit Implements ISoapDeSerializer Private Sub ISoapDeSerializer_Start(ByVal node As PocketSOAP.ISOAPNode, ByVal ElementName As String, ByVal Attributes As PocketSOAP.ISoapDeSerializerAttributes, ByVal ns As PocketSOAP.ISOAPNamespaces) If Not Attributes.Exists("arrayType", "http://schemas.xmlsoap.org/soap/encoding/") Then Err.Raise vbObjectError + 9876, , "Array is missing arrayType attribute!" End If End Sub
Copyright © Simon Fell, 2000-2004. All rights reserved.