ValidateXmlAgainstXsd
Methode (Function) · gibt Boolean zurück
ValidateXmlAgainstXsd ist eine Methode der Klasse Aloaha_ZUGFeRD.XML im Aloaha ZUGFeRD SDK.
Beschreibung (aus der SDK-Dokumentation): Validates an XML file against an XSD schema. The messages can be read with GetXSDValidationErrors.
Rückgabe: True if no validation message was reported; False if validation errors occurred or an exception was raised (e.g. file not found or invalid schema).
Deklaration
Public Function ValidateXmlAgainstXsd(ByVal xmlPath As String, ByVal xsdPath As String, Optional ByVal schemaNamespace As String = Nothing) As Boolean
Parameter
| Name | Typ | Pflicht | Beschreibung |
|---|---|---|---|
xmlPath | String | erforderlich | Path of the XML file |
xsdPath | String | erforderlich | Path of the XSD schema file |
schemaNamespace | String | optional (Standard: Nothing) | Target namespace of the schema; if empty the namespace from the XSD is used |
Aufruf (VB.NET)
Dim alo As New Aloaha_ZUGFeRD.XML(Aloaha_ZUGFeRD.iXML.ZUGFeRDProfile.comfort, False, LicenseKey)
' …
Dim ergebnis = alo.ValidateXmlAgainstXsd(xmlPath, xsdPath)
COM-Schnittstelle
ValidateXmlAgainstXsd ist Mitglied der Schnittstelle Aloaha_ZUGFeRD.iXML (Position 321 von 328) und damit auch aus VB6, VBA/Access und anderen COM-Clients über CreateObject("Aloaha_ZUGFeRD.XML") aufrufbar. Neue Mitglieder werden immer am Ende von iXML angefügt, damit bestehende COM-Clients unverändert weiterlaufen; nach einem Update die Typbibliothek neu registrieren.