PC SOFT

WINDEVWEBDEV AND WINDEV MOBILE
ONLINE HELP

Home | Sign in | English UK
New WINDEV, WEBDEV, WINDEV Mobile 24 feature!
WINDEV
WindowsLinuxUniversal Windows 10 AppJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadApple WatchUniversal Windows 10 AppWindows Mobile
Others
Stored procedures
<xmlDocument variable>.ValidDocument (Function)
In french: <Variable xmlDocument>.DocumentValide
Validates an XML document from an XSD schema.
Versions 17 and later
iPhone/iPad This function is now available for iPhone/iPad applications.
New in version 17
iPhone/iPad This function is now available for iPhone/iPad applications.
iPhone/iPad This function is now available for iPhone/iPad applications.
Versions 18 and later
Universal Windows 10 App This function is now available in Windows Store apps mode.
New in version 18
Universal Windows 10 App This function is now available in Windows Store apps mode.
Universal Windows 10 App This function is now available in Windows Store apps mode.
Versions 21 and later
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
New in version 21
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
Universal Windows 10 App This function is now available in Universal Windows 10 App mode.
Example
// Validation from the schema defined during the declaration
cMyDoc is xmlDocument, description = "ProjectXSDSchema"
IF cMyDoc.ValidDocument() = False THEN
Error(ErrorInfo())
ELSE
Info("The XML document is valid")
END
// Validation with the schema passed in parameter
cMyDoc2 is xmlDocument
IF cMyDoc2.ValidDocument("XSDSchemaOfProject") = False THEN
Error(ErrorInfo())
ELSE
Info("The XML document is valid")
END
Syntax
<Result> = <XML document>.ValidDocument([<XSD schema>])
<Result>: Boolean
  • True if the validation is successful,
  • False otherwise. To see the error details, use ErrorInfo.
<XML document>: xmlDocument
Name of xmlDocument variable containing the document to validate.
<XSD schema>: Optional character string (with quotes)
Name of schema that will be used to validate the XML document.
  • If this parameter is specified, the specified XSD schema is used to validate the document.
  • If this parameter is not specified, the schema specified during the declaration is used (declaration using the following syntax: cMyDoc is xmlDocument, description="MyXSD").
  • A WLanguage error is displayed if the schema specified during the declaration is not valid.
Note: If the XML document was declared with a description of XSD schema, the validation is automatically performed during the backup by XMLSave.
Component : wd240xml.dll
Minimum version required
  • Version 24
This page is also available for…
Comments
Click [Add] to post a comment