ONLINE HELP
 WINDEVWEBDEV AND WINDEV MOBILE

This content has been translated automatically.  Click here  to view the French version.
Help / WLanguage / WLanguage functions / Standard functions / XML file functions
  • Properties specific to the xmlNamespace variables
WINDEV
WindowsLinuxJavaReports and QueriesUser code (UMC)
WEBDEV
WindowsLinuxPHPWEBDEV - Browser code
WINDEV Mobile
AndroidAndroid Widget iPhone/iPadIOS WidgetApple WatchMac Catalyst
Others
Stored procedures
The xmlNamespace type is used to handle the XML namespace of a node attribute in an XML document.
The namespace allows you to use in the same XML document attributes with the same name and different definition or several attributes with the same name on a given node.
This type of variable is used by:
Note: For more details on the declaration of this type of variable and the use of WLanguage properties, see Declaring a variable.
Example
// Ajoute dans une balise l'entrée "xsi" et une référence "xsd" afin d'avoir :
// <?xml version="1.0" encoding="UTF-8" ?> 
// <BaliseDocument xmlns:xsi="http://www.w3.org/VotreUrl" 
//	xsi:noNamespaceSchemaLocation="VotreFichier.xsd">
// Exemple
// <Suite>
// Exemple pour type xmlNamespace
// </Suite>
// </BaliseDocument>

MonDocXML is xmlDocument
nNamespace is xmlNamespace
nNoeud is xmlNode dynamic 
nNoeud = MonDocXML.BaliseDocument

MonDocXML.BaliseDocument = "Exemple"
nNamespace.Name = "xsi"
nNamespace.URI = "http://www.w3.org/VotreUrl"
Add(nNoeud..NamespaceDeclared, nNamespace)
nNoeud:noNamespaceSchemaLocation..Value = "VotreFichier.xsd"
nNoeud:noNamespaceSchemaLocation..Namespace = nNamespace

MonDocXML.BaliseDocument.Suite = "Exemple pour type xmlNamespace"

XMLSave(MonDocXML, fExeDir() + ["\"] + "test.xml")
ShellExecute(fExeDir() + ["\"] + "test.xml")
Properties

Properties specific to the xmlNamespace variables

The following properties can be used to define the characteristics of xmlNamespace variables:
NameType usedEffect
NameCharacter stringName of the namespace in the XML document.
This name is used in the XML source code to prefix the ambiguous attributes.
URICharacter stringLocation of the definition of the namespace.

Minimum version required
  • Version 15
This page is also available for…
Comments
Click [Add] to post a comment

Last update: 03/27/2025

Send a report | Local help