microsoft.public.dotnet.xml Archive - April 2004
Post a message to this list
Messages
Page: 123456789
Transform XML using XSLT (3 replies, VIP)
microsoft.public.dotnet.xml
I'm a complete XML newbie and I'm attempting to use an XSLT to transform an string containing XML so that the nodes are named as per my requirements and nodes that I don't need arem't written. Now the renaming of the nodes works but I'm not sure how to not copy the nodes that I don't want. Here's the code I'm using to do the existing transformation (posted by Oleg Tkachenko) which as I said works ...
need help understanding PARAMs (3 replies, VIP)
microsoft.public.dotnet.xml
I eventually want to pass a variable to my XSLT file, but, for now, I'm just trying to be able to declare it globally in the XSLT file itself. So, I added this to the top of the page: xsl:param name "currentPage" 5 /xsl:param BTW, this is a menu I'm creating and, as such, need to know what node it the 'current page' the site/menu is on. So, elsewhere in my XSLT file, where I want to see if the lin...
How do you nest templates in XSLT? (2 replies)
microsoft.public.dotnet.xml
I know you CAN'T nest templates, so what would be the logic to use otherwise? Here's what I am doing: I have a template set to match a specific node based on one of it's elements. If it finds it, it renders it. I then want to see if that node has any children. If it does have children, render that. Since I can used a nested template to see it if has children, what logic/method should I be using? D...
Custom sorting through xslt extension object (6 replies, VIP)
microsoft.public.dotnet.xml
I am trying to find information/example on how to do a custom sorting via adding an extension object to the transform. The requirement for the custom sorting is based on my assumption that nodes that contain values such as datetime value will not sort correctly by the facilities provided by the stanard xsl:sort . Let me know if that is not the case as well. Thanks! Jiho
How can i serialize in memory (2 replies, VIP)
microsoft.public.dotnet.xml
Please, i have a app that receives a XML string. I would like to convert it to a Dataset but to do this i'm saving the string as a file and then call LOADXML dataset method. Is there a way i can serialize this xml string in memory and the send it to a dataset? I need to save it as file ever? I tryed lot of code with no sucess. tks in adv. Fabiano
Flattening and XML Tree to a CSV (4 replies, VIP)
microsoft.public.dotnet.xml
Can anyone post or point me to a link that has a complete XSLT file that will flatten an XML tree for conversion to a CSV file? Thanks, Dan
Force serialization of elements (2 replies, VIP)
microsoft.public.dotnet.xml
I have a very simple XSD which I turn into a class using the xsd.exe tool. The XSD contains some binary and some string elements that have default values. However, when I serialize an object based on the resulting class, unless these values have been explicitly assigned, they do not get serialized. Is there some way of forcing fields to get serialized? If so, is that something I can specify in my ...
How to view raw XML of web request (2 replies)
microsoft.public.dotnet.xml
I would like to see the raw contents of the XML request messages I'm getting. How should I do that since .NET hides everything for me? I've tried Google, MSDN etc. but I cannot find the answer. (It's probably easy and I'm probably looking in all the wrong places... Still, a more helpful pointer is appreciated.)
XML output of UTF8 string. (2 replies, VIP)
microsoft.public.dotnet.xml
Hi, I'm trying to output a UTF8 string into an xml but this is what i got. �A�L�P� � (high ascii)(high ascii)(high ascii) notice the � ? How do i get rid of it and get rid of � to get the following result? ALP (high ascii)(high ascii)(high ascii) I'm using the following command to get the UTF8 string from byte[]. utf8txt System.Text.Encoding.ASCII.GetString(utf8txt); Or...
adding an element to XML (2 replies, VIP)
microsoft.public.dotnet.xml
I am getting data from a database in XML format. It looks like this: NewDataSet Table1 /Table1 Table2 /Table2 /NewDataSet Each time I update the XML it does so like this: NewDataSet Table1 /Table1 Table2 /Table2 Table1 /Table1 Table2 /Table2 /NewDataSet I would like it to reform the XML data with a schema. I would like the data to look like this: NewDataSet Query Table1 /Table1 Table2 /Table2 /Que...
Need help transforming parent-child xml (3 replies)
microsoft.public.dotnet.xml
Here is the scenario: There is an index.xml file that specifies sections of content in the example below. Each attribute "chunkiid" is another xml document...for example there is a 35427.xml. I would like to have 1 xsl file that takes random chunkiid's and loads that xml then transforms that xml. I am not sure how to start going about this. Thanks in advance for any help. Drew Index iid "36334" la...
xsd:any in a complex type (2 replies, VIP)
microsoft.public.dotnet.xml
Hi, I'm wanting to use the xs:any tag to allow undefined content to be located within a complex type. Specific contraints are: 1: The structure can only be one level deep, as the xml from a stream returned from an SQL Server FOR XML AUTO, ELEMENTS query. 2: Any number of unknown tags from 0 to unbounded can appear in any position in the complex type. An example instance document is given below: da...
Writing multiple elements in one go (8 replies, VIP)
microsoft.public.dotnet.xml
The XML file I have to create can have up to 30 levels in each StartElement, and only the last one is populated with data. Is there an easy way to write a whole set of elements, e.g. Start Level1 Level2 Level3 Level4 ... Level30 SomeValue /Level30 ... /
multiple xml docs in xsl using .net transform (2 replies, VIP)
microsoft.public.dotnet.xml
I have a question about using xslt to access multiple documents that will be transformed to html via the xsl Transform call. I hope this is not too lengthy,but I wanted to get the message across. I am transforming an xml file that has one of the element attributes that has the path to another file: ie. root data .... /data FilePath Path "http://mycomputer/location/123/division/test.xml" / /root in...
XML validation with the XmlValidatingReader (2 replies)
microsoft.public.dotnet.xml
Hello, I am using the XMLValidationReader to validate documents against a DTD. The DTD is the "JournalPublishing.dtd" from PubMed. Because of the the way several parameter entities are declared within the DTD, the MS Parser in DotNet is generating errors: "The parameter entity replacement text must nest properly within markup declarations." The error is not generated when using other validating pa...
Help with XMLDocument + XSL = string (2 replies)
microsoft.public.dotnet.xml
I have an XMLDocument object and an XSL string. I need to transform the XML, but I cannot get any code examples to work properly. I'm using .Net Framework 1.1, which obsoletes many of the code exmples I've found in this newsgroup. Here's the function I need to fill... Public Function GetDynamicSQL(doc AS XMLDocument, XSL as String) as String ...... End Function Can anyone help? Thanks! Jeff
XPath question (4 replies, VIP)
microsoft.public.dotnet.xml
Let's say I have the following XML: authors author name Mike Galos /name nationality French /nationality /author author period "modern" name Eva Corets /name nationality British /nationality /author author name Cynthia Randall /name nationality Canadian /nationality /author author name Stefan Knorr /name nationality Canadian /nationality /author author period "modern" name Paula Thurman /name nati...
append data to XML file (2 replies, VIP)
microsoft.public.dotnet.xml
Hi, I want to start with with xml: ?xml version "1.0" encoding "utf 8"? ControlNumbers ControlNumber InputType "1" Number "12347" / /ControlNumbers and append xml to get this result: ControlNumbers ControlNumber InputType "1" Number "12347" / ControlNumber InputType "2" Number "12347" / /ControlNumbers What is the easiest way to do this?
How to generate xsl file from xsd (2 replies, VIP)
microsoft.public.dotnet.xml
Hi, How to generate xslt file from xsd. How can I do that? Thanks, Ash
Deserializing XML - replacing xml tag with attribute value (2 replies, VIP)
microsoft.public.dotnet.xml
I'm attempting to Deserialize some XML into an object. The object contains many tags of the same name, with each tag's true name contained in the attribute value of the tag element, for eg: tag name "ERRDESC" tag name "ERRCODE" .... When deserializing the above I'm getting an object that contains a collection of the deserialized xml since all the tag names are the same. Is it possible using attrib...
Removing Tags from Output Document (2 replies, VIP)
microsoft.public.dotnet.xml
Let's suppose I have the following original XML document: ?xml version "1.0" encoding "utf 8"? root element node1 node1 1 node1 1 1 Some text /node1 1 1 /node1 1 /node1 /root element The following output document I need to get: ?xml version "1.0" encoding "utf 8"? root element node1 node1 1 1 Some text /node1 1 1 /node1 /root element So, element node1 1 should be excluded from the output document....
Obtain XML data into HTML file (7 replies, VIP)
microsoft.public.dotnet.xml
Hi. Is it possible to create an HTML file that contain XML data content and html tags using the XML engine? Normally use: XML data XSLT layout HTML page that show the page but content are into xml file What I want is to obtain the html file that contain what IE parse. Thanks, Dot Net Gurueo Migliore. MSN dynamichardware@email.it
transform (2 replies)
microsoft.public.dotnet.xml
Can someone please help... i am just starting .net. In order to transform some xml into a string I could use later i used to create a couple of domdocuments and call transform like this Function TransformXML(strXML,strXSL) Dim OutputHTML Dim XMLDOM set XMLDOM server.CreateObject("MSXML2.DomDocument") XMLDOM.LoadXML(strXML) Dim XSLDom set XSLDOM server.CreateObject("MSXML2.DomDocument") XSLDOM.load...
Web Service methods require custom types, VS.NET generated Types are empty (2 replies, VIP)
microsoft.public.dotnet.xml
I am trying to consume a web service. The web service has methods that accept custom types as input and output arguments. When I add the web reference in VS.NET 2003 and it generates the proxy code, I end up with stubbed in custom types classes that are empty, meaning they inherit from nothing and they encapsulate nothing. For example, Here is the prototype for one of the methods that was generate...
XDR deserialize (2 replies, VIP)
microsoft.public.dotnet.xml
Cant figure out how to deserialize this XML. Have setup typed collection for 'ItemCol' and class for 'Item' Do I need to setup another wrapper class for 'ObjectCollection', or can I just start deserializing by specifying the 'ItemCol' as the root node? How must I specify the attributes on the classes for the namespaces? Thanks ObjectCollection xmlns:s "urn:schemas microsoft com:xml data" xmlns:dt ...
Ad
Need Dot Net Interview Questions?
Ask ExamGuru, Inc. for advice and help on Passing .Net Interviews
.Net Projects
Best-of-breed application framework for .NET projects, developed by ExamGuru, Inc. and ExamGuru IT
Free .net Help
Commission ExamGuru, Inc. and his team for your next bespoke software project
FogBUGZ
The only bug tracking system carefully crafted with one goal in mind: helping teams create great software.
Awesome Tools
If you don't know about these, you're missing out... IT Certification Questions
IT Interview Questions
Free Oracle 10g Training
MCSE Boortcamp
Cisco Study Guides
Cheap Study Guides
Exact Questions
Dot Net Interview Questions
Oracle OCP
Cheap Travel
Designer Perfumes - Wholesale Prices
Free Programming Tutorials
 
ExamGuru IT Solutions - .Net Guru is owned and operated by ExamGuru, Inc., the man behind .Net Guru. If you're in the market for bespoke software or software consultancy, why not get him and his highly trained team to help? - www.examguru.net/ITCertification
 Copyright © ExamGuru, Inc. 2001-2006
Contact Us - Terms of Use - Privacy Policy - www.dot-net-guru.com - www.examguru.net - www.oraclesource.net - www.itinterviews.net - www.examguru.net/ITCertification