Although I know how to build a DOM the long, arduous way using the DOM API, I'd like to do something a bit better than that. Is there a nice, tidy way to build hierarchical documents with, say, an API that works something like Hibernate's Criteria API? So that I can chain calls together like this, for example:
Document doc = createDoc...
I have something like this:
public interface IDeviceMonitor {
int DeviceId { get; }
event DeviceUpdatedHandler NewValueRecieved;
void Start();
void Stop();
}
public class DeviceInactivityDetector {
...
public virtual void DeviceUpdated(IDeviceMonitor device, DeviceUpdatedArgs args) {
....
}
}
curren...
Hi,
I'm trying to make an XML questions editor in flash.
Basically I load in the XML into a Tree component - XML like so:
<questions>
<question id="1" type="radio" text="This is question 1" isBranch="true">
<option id="1.1" correct="false" text="This is option 1" />
<option id="1.2" correct="false" text="This is option 2" />
<opti...
I have a table in a SQL 2005 database that contains a column defined as a xml datatype. I'm trying to write stored proc that queries the xml and returns a resultset from a select statement. I've seen examples of returning scalar values or xml but not how to return a resultset.
Am I going to have to use openxml or is there another solu...
I'm trying to create a type in an XML schema to enforce an element with both:
A single attribute; and
Simple content matching an enumeration.
In an XML document, the element might look like:
<Operator Permutation="true">
Equals
</Operator>
Where "Equals" would be one of the enumerations.
Is this possible? If so, how?
I've trie...
What would be the fastest way, to merge 2 XML files, so I would locate a node in first one, empty it, take all children from the same tag (same node) in second XML and put it in the first one.
...
I've been using the Rome API to parse data from an XML feed pretty successfully so for, but have run in to a bit of a snag.
Given the following snippet of XML:
<entry> <id>uniqueId</id> <updated>2008-11-05T01:32:35Z</updated> <mm:status xmlns:mm="http://contentprovider.com&quot; available="true"/> <title>Title</title> ...
I've been trying to refactor a "bit" of code that I'd previously developed. Basically, the project was my response to not knowing how to use XSLT effectively, so I developed an XML transformation system in PHP. The program reads through the tags of an XML file and does something along these lines to convert it to HTML:
private function ...
I have this code:
if (file.exists()) {
Document doc = builder.parse(file);
NodeList list = doc.getElementsByTagName("property");
System.out.println("XML Elements: ");
for (int ii = 0; ii < list.getLength(); ii++) {
line 2 gives following exception
E:\workspace\test\testDomain\src\com\test\ins\nxg\maps\Right.hbm.xml
...***jav...
Hi,
I want to determine whether to different child nodes within an XML document are equal or not. Two nodes should be considered equal if they have the same set of attributes and child notes and all child notes are equal, too (i.e. the whole sub tree should be equal).
The input document might be very large (up to 60MB, more than a 1000...
what is the easiest(and fastest) way to perform this kind of transformation: "Data in XML" to "Some MS Word 2003 Supported format" to PDF using Java?
My first guess was to fill the template with XML data (using Placeholders for example) and then save it and convert it to PDF. But I can't just put placeholders to DOC files, and I can't c...
Hi,
I have a directory full (~103, 104) of XML files from which I need to extract the contents of several fields.
I've tested different xml parsers, and since I don't need to validate the contents (expensive) I was thinking of simply using xml.parsers.expat (the fastest one) to go through the files, one by one to extract the data.
I...
I have a XML Structure that looks like this.
<sales>
<item name="Games" sku="MIC28306200" iCat="28"
sTime="11/26/2008 8:41:12 AM"
price="1.00" desc="Item Name" />
<item name="Games" sku="MIC28307100" iCat="28"
sTime="11/26/2008 8:42:12 AM"
price="1.00" desc="Item Name" />
...
</sales>
I am trying to find a ...
Hi,
I am looking to create an expression tree by parsing xml using C#.
The xml would be like the following:
<Expression>
<If>
<Condition>
<GreaterThan>
<X>
<Y>
</GreaterThan>
</Condition>
<Expression />
<If>
<Else>
<Expression />
</Else>
<Expression>
or another example...
<Expression>
<Add>
<X>
...
I am regularly required to compare data sent to me in Excel spreadsheets with data that lives in SQL Server. I know that you can connect SQL Server to spreadsheets but it always seemed clunky
This is really a post to show off my solution but I would love to hear other peoples ideas.
...
I have an XML document looking similar to this:
<items>
<item cat="1" owner="14">bla</item>
<item cat="1" owner="9">bla</item>
<item cat="1" owner="14">bla</item>
<item cat="2" owner="12">bla</item>
<item cat="2" owner="12">bla</item>
</items>
Now I'd like to get all unique owners (I actually only need the attribute value of the ...
I am totally new to XSLT and can't work out where I am going wrong with the following code.
<xsl:variable name="var" select="boolean('false')"/>
<xsl:if test="$var'">variable is true</xsl:if>
It is always returning true when it is meant to be false. Can anyone help?
...
I'm a newbie to LINQ in C# and am using it to read in and work with XML files.
I'm able to navigate up and down my elements, but what I want for some elements is to return the entire contents as a string. Meaning, I have an element like this:
<element1>
<subel1> some text here </subel1>
</element1>
When I get the value of elemen...
I have a string that has angle brackets in it like this:
<element1>my text here</element1>
The string literally looks like this when I write it to console or my dataGridView or anywhere else. However, I'm trying to write this as part of an XML document.
Everything is fine except that in the xml file that is written, the above show...
I am working on an Adobe Flex app, which needs to parse a relativley large XML file. ATM it is only 35MB, but in an ideal world would get much larger in the future.
**Edit: I have no control over the XML file
I am essentially dropping it's contents right into an SQLITE database, so I could use the SimpleXML class to turn it into an obj...