xml

Best way to parse an XML String in Java?

I am parsing a string in Java using javax.xml.parsers.DocumentBuilder. However, there is not a function to parse a String directly, so I am instead doing this: static public Document parseText(String zText) { try { DocumentBuilderFactory dbFactory = DocumentBuilderFactory.newInstance(); DocumentBuilder dBuilder = dbFactory.newDocu...

How can I search a large XML data set?

I have a DataModule with XML and I need do a search... Unfortunately there are more than 300,000 records and I can't make a loop to check one-by-one. Is it possible to make a query without using a database? Is there another solution? ...

ImportXmlWithProgress not updating result attribute of importjob

I tried to write some code to import a large customization containing 50+ entities. I used the microsoft article 'ImportXmlWithProgress Message (CrmService) as a bases, but was not getting the output I expected. The 'job.data' in the following code was not changing from the original parameterxml data. So this implies to me that the imp...

Export XML to Excel spreadsheet using Javascript/classic-ASP

I'm trying to export XML data from a web page to a spreadsheet using javascript. So far I've just tried the very simple: Sub Export Response.ContentType = "application/vnd.ms-excel" <script> var XML = document.getElementById("xmldata"); window.open(XML); </script> End Sub This t...

Converting XML input from multiple lines to one line

I have an xml like this <address> <street>abc</street> <number>123</number> </address> <address> <street>abc1</street> <number>345</number> </address> ... ... <address> <street>xyz</street> <number>999</number> </address> I want to be able to convert this to <address><street>abc</street><number>123</number></addr...

how to use XML to store all items to an array (C#)

ok, so i have a text file system worked out. but its a mess, and i want to organize it.. so here is an example of what i have saved in my file.txt feild1 feild2 feild3 feild4 myname myhashedpass [email protected] more stuf etc etc etc etc so, each line is converted into four strings, string Name; string Pass; string Email; string Host...

How to attach an xsd file to xml in .net?

I have one xsd file having definition of two tables suppose A and B, and i want to create two files as A.xml and B.xml. When i enter the data in these xml files data should validate with xsd My question is how can i validate the data while entering data in xml file? ...

Explanation about Annotations

Hi, Can anyone please explain what the following two paragraphs mean, in simple english? (Taken from http://www.ibm.com/developerworks/java/library/j-cwt08025.html) "Annotations are more flexible in terms of how you use them, with options for whether the annotation information is to be included in class files output by the c...

Scottish Higher Education Descriptor, What do these terms mean?

http://docs.google.com/gview?a=v&amp;q=cache:spO3YR6dNcoJ:www.sqa.org.uk/sqa/files/hn/F6C135.pdf My class has just been discussing the course descriptor for the SQA Higher National Unit specification (Scottish higher education unit), We’ve been waiting for a response from the exam board for a few weeks and none has been forthcoming, per...

How can I extract some XML data from a URL using XML::Twig?

I want to get a specific string, for example 123 in <received>123</received> from some XML that will be retrieved from a URL. I have write a code but stuck with an error message: Attempt to bless into a reference at /usr/share/perl5/XML/Twig.pm line 392. How can I solve it? The code: use XML::Twig; use LWP::Simple; my $url = '...

Extracting MBSA XML Data using Powershell

I'm trying to extract various information from Microsoft Security Baseline Analyser 2 results and helpfully found this script: http://fatbeards.blogspot.com/2009/01/powershell-mbsa-logs.html, however I also need a tally of CRITICAL updates, not just all updates as the script currently does. Critical updates are denoted with Severity="4"...

looping through xml in .net

I'm looping through Some xml in .net and assigning Xml elements to string variables. Those variables are passed into a method that takes three arguments. That method runs a stored procedure in SQL Server 2005 that queries the database with those three arguments. The method and sproc run fine when passing in the arguments manually. But ...

Programmatically injecting Xml data into an Excel 2007 workbook

I need to create an Excel 2007 template workbook and devise the means to programmatically populate it with a dataset. The template workbook should include all of the formatting and boilerplate content that will appear in the final result, but will not inlcude any data rows. The data injection process must be able to dynamically insert d...

Is it possible to create XML files using Hpricot?

I know I can parse XML using Hpricot, but is it also possible to create files? All the tutorials I found only demonstrate parsing. ...

XSLT mixed content node

I have a quite stupid question. How can I make sure that my XML mixed content node doesn't get mixed up? I have, say, an XML structure resembling this. <root> <book> <title>Stuff</title> <description> This book is <i>great</i> if you need to know about stuff. I suggest <link ref="Things">this one</link> if you need ...

Excel sheet with XSLT transformation ... need protection

Hello, I need to export DataSet result to Excel file (using dataset, XSLT transformation and XML generation => XML spreadsheet). That's work, but I'd like to protect this sheet. The reader can only make change in some dropdown, in some cell but other change are not allowed. The only changes allowed are some specific cells (value or drop...

IXMLDOMDocument2 to string javascript

I have a IXMLDOMDocument2 type document. I would like to see the xml for this document. How can I turn it in to a string so I can view it? I am using javascript. The .text properity is just "". ...

Fastest way check xml well formed, and pinpoint problems for Windows Developer

Just wondering if somebody could suggest the quickest tool for the situations where you know somebody committed some invalid XML and you want to find it really fast. Right now I've been using XML Copy Editor. Any other suggestions? I will eventually put validation commit hooks to prevent people from committing invalid .xml files. Tha...

display xml contents in to a listview in winforms

Ihave an xml file sample.xml <?xml version="1.0" standalone="yes"?> <DataSchema xmlns="http://tempuri.org/DataSchema.xsd"&gt; <ManagedObject> <Label>sam</Label> <Owner>00000000-0000-0000-0000-000000000000</Owner> <ClassID>00000000-0000-0000-0000-000000000008</ClassID> <DefaultApp>00000000-0000-0000-0000-00000000000...

libxml-ruby and multiple namespaces

having this xml declaration: <didl:DIDL xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:didl="urn:mpeg:mpeg21:2002:02-DIDL-NS" xsi:schemaLocation="urn:mpeg:mpeg21:2002:02-DIDL-NS http://standards.iso.org/ittf/PubliclyAvailableStandards/MPEG-21_schema_files/did/didmodel.xsd"&gt; what is the way to defin...