Questions tagged [xmlnode]

XML document unit (element, entity, attribute, text, comment, notation, even document or it's fragment).

XML document unit (element, entity, attribute, text, comment, notation, even document or it's fragment). XML node types

486 questions
4
votes
1 answer

Minidom:Get all the attributes of a selected node?

I recursively pass through all the nodes in an XML: def verify_elements_children(root): if root.childNodes: for node in root.childNodes: if node.nodeType == node.ELEMENT_NODE: if node.tagName in…
Eduard Florinescu
  • 16,747
  • 28
  • 113
  • 179
3
votes
1 answer

Setting node value using XPath Java

I'm trying to set a node value via an XPath. I have the following but it doesn't seem to change the actual files value. XPathFactory factory = XPathFactory.newInstance(); XPath xPath = factory.newXPath(); xPathExpression = "//test"; xPathValue=…
mlevit
  • 2,676
  • 10
  • 42
  • 50
3
votes
0 answers

XmlNode returns in OuterXml unexpected namespace xmlns

I have XmlNode object with next attributes: But when i call OuterXml Property i have all those attributes and also xmlns attribute with namespace included. But i dont wath to have this namespace there! How can i set to node properties not to show…
Ievgen
  • 4,261
  • 7
  • 75
  • 124
3
votes
5 answers

Set x XML node to value in Powershell

I have this PowerShell script in which values for an XML-file will be set by the script. This works perfectly fine when all child nodes are uniquely named. However, I'm adapting the XML-file to one where some nodes are repeated. Now I get an error…
Sunfile
  • 101
  • 1
  • 4
  • 22
3
votes
1 answer

Xml.nodeValue causes "Bad node type" error

class Main extends Sprite { public function new() { super(); try { var xml:Xml = Xml.parse("6"); trace(xml.nodeType); for (x in xml.elementsNamed("count")) …
Gulvan
  • 305
  • 2
  • 12
3
votes
1 answer

Remove
from xmlnode

My XML could look like this:

First Text
Second Text

Loading the xml-file, going through all nodes with the following code: XmlDocument doc = new XmlDocument(); doc.Load(filepath); foreach…
kyro0
  • 45
  • 3
3
votes
2 answers

XMLNode. HasChild considers InnerText as a child node

I’m working on a windows form application I’m trying to see if a certain xml node has child nodes, in the first lines of my code I used OpenFileDialog to open an xml file; in this case the xml sample below.
R. Ben
  • 35
  • 6
3
votes
1 answer

How to make a copy of a XML node with all their child nodes and values but different name C# .NET

I'm trying to make a copy of a XML node and all their child nodes but different XML parent node name, but is throwing me an error, this is the xml file: 0.0.0.0 12 USER
Javier Salas
  • 1,064
  • 5
  • 15
  • 38
3
votes
2 answers

is there any easy wasy to convert the XML output from sharepoint GetListItems() to a DataTable

i am able to retrieve data from sharepoint com.sharepoint2.Lists lists = new Lists(); lists.Credentials = new System.Net.NetworkCredential("user", "pwd", "domain"); lists.Url =…
leora
  • 188,729
  • 360
  • 878
  • 1,366
3
votes
1 answer

Getting XPath for node with XmlReader

How to get XPath for the current node with XMLReader? E.g.: 1 So I need to get XPath for 1 which is Employee/Entity/Id. Any ideas? using (var reader = XmlReader.Create(basePath,…
user1618825
3
votes
1 answer

Dealing with empty XML nodes in R

I have the following XML file (I am missing the root node but the editor is not allowing me--please assume there is a root node here):
3
votes
2 answers

Nodes selection inside HtmlNodeCollection with HTML Agility Pack

I have html structure like that:
Reno
  • 1,291
  • 4
  • 17
  • 29
3
votes
2 answers

Read nested XML with XmlNode

i tried to read nested XML with xmlnode but i got one issue here is my xml file
Laxus
  • 43
  • 1
  • 6
3
votes
5 answers

not sure how to use XmlNode in C#

In C# I need to use XmlNode to get values from these attributes as follows: Root element (ServerConfig): type version createDate Child nodes (Items): name source destination XML:
user235973457
  • 331
  • 4
  • 9
  • 24
3
votes
3 answers

Get value from node with same name

I'd like to retrieve information from an XML file, however the way it's formatted is pretty strange. Here it is...
Waverunner
  • 79
  • 1
  • 2
  • 6