vbscript - Is this a proper XML syntax -
I was wondering if this was a proper XML syntax, because I used VBscript and I actually used this document The need to delete a node is not able to do this
. & Lt ;? Xml version = "1.0" encoding = "utf-8" & gt; & Lt; DBM & gt; & Lt; Server & gt; & Lt; Server name = "PCTEST" & gt; & Lt; Reference & gt; & Lt; Database name = "TES1" path = "\ C $ \ Build" /> & Lt; / References & gt; & Lt; / Server & gt; & Lt; / Server & gt; & Lt; / DBM & gt; Try "itemprop =" text "> after the
xmlDoc set = CreateObject ("Microsoft.XMLDOM") xmldoc.async = false xmldoc.loadXml _ "to & lt ;? xml version = '1.0' encoding = 'utf-8' & gt ;?" & Amp; _ "& Lt; dbm & gt;" & Amp; _ "& Lt; server & gt;" & Amp; _ "& Lt; server name = 'pctEST' & gt;" & Amp; _ "& Lt; context & gt;" & Amp; _ "& Lt; database name = 'tes1' path = '\ c $ \ build' / & gt; & Amp; _ "& Lt; / references & gt;" & Amp; _ "& Lt; / server & gt;" & Amp; _ "& Lt; / server & gt;" & Amp; _ "& Lt; / dbm & gt;" 'NodeToBeRemoved' s single node set is being removed // xmldoc.selectSingleNode // ("// database [@name = '' TES1 ']") If nothing is nodeToBeRemoved then NodeToBeRemoved.parentNode.RemoveChild nodeToBeRemoved end if '' // Removing multiple nodes nodesToBeRemoved = xmldoc.selectNodes ("// database") set for each nodeToBeRemoved nodesToBeRemoved nodeToBeRemoved.parentNode.RemoveChild nodeToBeRemoved Next '' // Warning in xmldoc.xml
Comments
Post a Comment