I'm using HierarchicalConfiguration for use with XML configuration files. Works great.
But now I need to report meaningful information as an error. I would like to print the offending fragment of XML (or at least report line #), but I can't seem to get hold of an XML object or string from a HierarchicalConfiguration object. Help! What ...
Hi all,
I am connecting to a simple XML over HTTPS web service and getting a security exception. My question is whether you think the cause of this is the cert on the web server, so I should talk to the server admin or if my client code should be handling this. I would love to hear if anyone has encountered and solved this issue. Is the...
I am using BeautifulStoneSoup to parse an XML document and change some attributes. I noticed that it automatically converts all XML tags to lowercase. For example, my source file has <DocData> elements, which BeautifulSoup converts to <docdata>. This appears to be causing problems since the program I am feeding my modified XML document t...
Hi,
I am trying to build a complex xpath expression which will answer the following condition.
From the XML data below, returns the User entity which:
His loginname is "user1"
His name is "User 1"
He has 2 different profiles values which are "operator" and "admin" (I don't know the exact order ahead)
<user>
<login>user1</lo...
Hi,
I need a nice way to be able to remove all namespace from an XML document in C++. Currently the doc is loaded into a MSXML2::IXMLDOMDocument2Ptr class.
Can't currently see any methods that can do this
Thanks
...
I am trying to traverse through a simple sitemap (adding and deleting elements on the fly.) This is the sample layout
<?xml version="1.0" encoding="UTF-8"?>
<urlset
xmlns="http://www.sitemaps.org/schemas/sitemap/0.9"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.sitemaps.org/schem...
Greetings!
This is quite a newbie question but forgive me. Can anyone recommend a good place, either site or book, to get up to speed on the XML Frameworks with .Net. I think I have the basics down but I have the feeling it's not as elegant as it could be.
For example:
When to use XMLDocument or XMLReader for finding elements
How c...
I have a GPX file with a GPS track. Now I want to calculate the distance I covered with this track.
What's the best way to calculate this?
...
I am converting about 4000 text files that contain HTML into MySQL database entries. Seems like an easy way to do this would be to add a couple lines to the HTML to make them appear as XML files, then XSLT the XML into MySQL INSERT statements. (Building a CSV would also work, but less optimal IMHO). I've tried doing this but am having li...
I'm looking in Web.Config to add a simple (from a book) amendment -
<configuration>
<appSettings>
<add key="SupportEmail" value="[email protected]" />.
</appSettings>
</configuration>
However in the web.config I see there is only the following sign/bracket/block(?):
<appSettings/>
I can't find the opening . And isn't that an i...
I have a java program that parses an XML document using xerces API.
My parsing class extends org.apache.xerces.parsers.XMLDocumentParser, overloading the startElement, endElement, characters methods.
Since it's a complicated XML document that is written by hand (mainly some kind of configuration elements), classic validation by xsd or ...
Using C#...I have a small app that creates objects from a class, and adds them to an object collection and it does some UI stuff along the way to display certain values from the currently selected object in the collection (Using WPF UI). So I want to add the ability to let the user save his object collection to a file, so they can load i...
I have an application written in .NET 1.1 that calls XmlDocument.Load on a URL. Just recently the xml file was updated. Now whenever I call XmlDocument.Load, the old file is returned. When I hit the same URL from a browser, I see the new file. I deleted all temporary files from IE and I still see the same issue. Any thoughts on why ...
I am developing for a website that has an event "listing" service. It uses an rss feed (located at the web root under the name 'rss.xml') to give an RSS feed of the events to users who are interested in the service.
I've been tasked with developing a blog for the website. I have the blog piece done, but I'm not sure the best way to inte...
I have an input XML file which I need to copy 1:1 to the output, except for one subelement which contains subitems that need to be sorted.
<?xml version="1.0"?>
<top>
<elementA />
<elementB />
<contents>
<contentitem>
<id>3</id>
<moretags1 />
<moretags2 />
</contentitem>
<contentitem...
I am writing a client windows app which will allow files and respective metadata to be uploaded to a server. For example gear.stl (original file) and gear.stl.xml (metadata). I am trying to figure out the correct protcol to use to transfer the files.
I was thinking about using ftp since it is widely used and a proven method to transf...
I create an IEnumerable object that just contains the nodes I want from an xml file:
IEnumerable<XElement> rosters = XDocument.Load("roster.xml")
.Elements("rosterlist")
.Elements("roster")
.Where(w => w.Element("di...
I try to generate such XML using REXML
<root>
<add key='foo' value='bar'/>
</root>
But what I get is (notice that key/value order)
<root>
<add value='bar' key='foo'/>
</root>
Code:
require 'rexml/document'
include REXML
doc = Document.new
doc.add_element('root')
el = doc.root.add_element('add')
el.add_attribute('key', 'foo')
...
Hi,
I've asked few people why using xml as a parameter in stored procedure doesn't work and everyone said , that's just the way it is. I can't belive that.
command.Parameters.Add("@xmldoc", SqlDbType.Xml);
That's where compiler returns error and I can't use NVarChar beacouse it's limiteed to 4k sings. XML would be perfect as it can b...
I have an XML schema and an instance document I get from a customer.
For example the document can be:
<doc>
<carId>12</carId>
</doc>
And it is valid according to the schema.
I would like to annotate this with my attributes:
<doc>
<carId myns:valid="true">12</carId>
</doc>
I would like the annotated document to be va...