Archived Months
June 2003
July 2003
August 2003
September 2003
October 2003
November 2003
December 2003
January 2004
February 2004
March 2004
April 2004
May 2004
June 2004
July 2004
August 2004
September 2004
October 2004
November 2004
December 2004
January 2005
February 2005
March 2005
April 2005
May 2005
June 2005
July 2005
August 2005
September 2005
October 2005
November 2005
December 2005
January 2006
February 2006
March 2006
April 2006
May 2006
June 2006
July 2006
August 2006
September 2006
October 2006
November 2006
December 2006
January 2007
February 2007
March 2007
April 2007
May 2007
June 2007
July 2007
August 2007
September 2007
October 2007
November 2007
all groups > dotnet xml > march 2005

Filter by week: 1 2 3 4 5

Loading XSL
Posted by James Doughty at 3/31/2005 11:55:22 PM
Hi, I know how to load a XSL from a file and make it do the XSL Transformations acrooss my document. Here is what I need to do. I need to load the XSL not from a file but from a string, which is stored in a sql server table. I know the XSL in the table is corret since it's what I used about...more >>


XmlDocument
Posted by Z at 3/31/2005 4:49:03 PM
Hi, I am using the XmlDocument class in my program. I fount there are no methods like GetAttributesByName or GetTagsByName, so I had to write my own (not very hard). I am a bit surprised that methods like (frequently needed) this do not exist. As I do not have much expirience I wonder if t...more >>

Access XmlSchema properties?
Posted by Chris at 3/31/2005 9:01:02 AM
I'd like to be able to access the elements in an XSD/XmlSchema object to determine things like the datatype. Can this be done without explicitly running validation on a document? Can I programatically access the elements via an XmlSchema object to determine datatype (or other properties)? T...more >>

sorting a xmlDocumnet
Posted by moital at 3/31/2005 8:25:13 AM
i am looking for a c# way to sort an xmlDocument notes the input of the function is a xml as string, and a path of the to be sorted nodes and the attribute to sort by as any one implement something like it ? -- moital ...more >>

Serializing private members
Posted by Gregory Khrapunovich at 3/31/2005 6:41:35 AM
Hi, I have a class that contains user configuration settings and I would like to save it on disk when program exits and restore data when program starts. XmlSerializer seems like a natural choice. And it works fine. There is only one problem. All members of the class must be declared publ...more >>

Checkboxlist with XML
Posted by me at 3/29/2005 11:07:05 PM
Hello, I have a novice question: How do you populate a checkboxlist with XML data? TIA ...more >>

Namespace Question
Posted by John Jenkins at 3/29/2005 8:46:41 PM
I sent this question in before, so apologies. I have a number of schemas which I add into a schema collection. A number of the schemas define types, the others contain business context message details (e.g. updating an employee etc). The schemas which define general types have their own namesp...more >>

easy: readxml() with basic.net
Posted by Steiner Hubert at 3/29/2005 8:10:23 PM
hello, i use this code: Dim ds As New DataSet ds.ReadXml(Me.txtImportFile.Text) at the readxml line i have the following error: "FormatException" please help ...more >>



parent child relations
Posted by Jonathan Crawford at 3/29/2005 6:57:39 PM
Hi I have an xml schema with a customer/order master child relationship managed by a dataset In the windows form I have the customer fields bound to the customer node and a datagrid for the orders My problem is that the relationship in the schema is not carried onto the form I would ...more >>

XML Serialization Help
Posted by Jeff T. at 3/29/2005 8:37:16 AM
Hello, I have an existing set of C# classes that encapsulate our application data. They are in a heirachy with each subclass defining more specific types of data. I would like to serialize these data objects as XML but perserve the relationships in the XML document. For example, if my classe...more >>

newbie question - replacing "invalid" nodes
Posted by Nick Wong at 3/28/2005 4:11:52 PM
Hi all, i am reading in an xml stream and validating it against a given schema. the objective is to "mark" "invalid" nodes (according to the xsd type defined, or some rules) with an attribute, and then pass this modified stream to another process in the pipeline. as an example, <bk:boo...more >>

minLength and maxLength
Posted by ray NO[at]SPAM cape.com at 3/28/2005 12:28:18 PM
My xsd has the following element: <xs:element name="Company" minOccurs="0"> <xs:simpleType> <xs:restriction base="xs:string"> <xs:minLength value="1" /> <xs:maxLength value="5" /> </xs:restriction> </xs:simpleType> </xs:element> when i change the maxLength to what i really ...more >>

XML to DTD, is there anything in VS.NET ?
Posted by Mike at 3/28/2005 11:55:02 AM
Hi! I have to create a DTD for a multilevel (30+ levels) XML file. I am looking for help in creating the bulk of the DTD automatically. Is there anything in VS.NET 2003 to help me out? I've looked and can only see Schemas. Is there anything out there I can use ? I found some tools but all of...more >>

XML File Size - Causing Problems
Posted by Brian at 3/28/2005 9:25:04 AM
Hello - thanks for your time. I've built an intranet site that uses an xml file as a data source for dynamic content. Currently the xml file is approximately 1 mb. The file will grow beyond this size as time goes on. The application works great locally, but when I run it on a production s...more >>

xml using datasets
Posted by Ramakant at 3/28/2005 12:00:00 AM
hi i am new at this...whats the better way to read xml files..create a dataset and read them using xml only for validation ... or use xmlreader to validate and read them? thanks in advance ...more >>

passing a nodeset into an xslt file.
Posted by amit L via DotNetMonster.com at 3/27/2005 3:51:47 PM
hi all. i've been trying to pass a nodelist (!=nodeset??) from my c# application to some xsl transform to use. the xsl code is as follows: <xsl:stylesheet version="1.0" exclude-result-prefixes="extern msxsl local xql" xmlns:xsl="http://www.w3.org/1999/XSL/Transform" xmlns:msxsl="urn:schema...more >>

XML serialzation
Posted by Stipe at 3/26/2005 12:00:00 AM
Hi! Because of the size of XML document, I'm trying to skip some elements in XML for the properties which are not changed during current session. I am holding those property names in array, and if property is not changed (it has old value) than I don't want to include it in XML. I know t...more >>

ASP querystring and XML
Posted by Don at 3/25/2005 6:35:09 PM
Hi: If somebody just gives me and asp page that returns XML, how do I consume that? Such as news.asp?page=id. This returns a page of XML in IE. What objects and properties in .NET should I research? Thanks, Do ...more >>

convert sql tables with parent-child keys of a nested structure into a nested xml file
Posted by Hazz at 3/25/2005 2:33:18 PM
I have 5 tables in SQL Server. Each with the following design and a sample chain of the relationships from the root (WRL - World) UUS is the 'Code' of the first table and it is the 'Parent' value of the second table, etc. Parent varchar 3 Name varchar 60 Code varchar 3 WRL United States U...more >>

DataSet.ReadXml with an extract from an xml file
Posted by Jeronimo Bertran at 3/25/2005 10:59:36 AM
Hi, I have an xml file that encapsulates a dataset definition within a set of tags (<dataset>)... here is an example <?xml version="1.0" encoding="utf-16"?> <dataset> <MyTable> <Field1>100</Field1> <Field2>200</Field2> </MyTable> </dataset> I first use an...more >>

How to get underlying Xslt content from XslTransform object
Posted by shell shell via .NET 247 at 3/25/2005 9:42:28 AM
How do you get the underlying Xslt stylesheet content from an XslTransform object that has been created and loaded with a stylesheet file or some text? Assume a method will create an XslTransform object, load it with a stylesheet file or some text, and return this object. public XslTransform C...more >>

XSLT transform XmlDocument to XmlDocument?
Posted by Gustaf Liljegren at 3/24/2005 3:43:54 PM
I just want to make a transformation on the fly, without having to save the XML document to a file before or after the transformation. I don't find any examples of this. I see that the XslTranform.Transform() method can return an XmlReader, but how can that reader be converted to an XmlDocu...more >>

need .Net APIs to create xml based on xsd
Posted by cindy liu at 3/24/2005 1:41:05 PM
Hi, I'd like to create xml string based on my xsd file. Is there any .Net APIs to do this? Like in BizTalk 2004, you can generate xml instance based on xsd file. Thanks in advance!!! Cindy...more >>

Editing XML from browser
Posted by Jimit at 3/24/2005 1:09:41 PM
Hi, What is the best way to provide the browser based XML editing for better user experience. Presently I am displaying xml in simple Text Area for editing in a browser and I am looking for some better approach. Any help would greatly help, Thanks, ...more >>

How to rewrite Dynamic XPath jscript evaluate in c#
Posted by David Laub at 3/24/2005 11:15:22 AM
I have no problems running the following dynamic XPath evaluator form MSXSL: <msxsl:script implements-prefix="dyn" language="jscript"> evaluate(context, expression) { return context.nextNode().selectNodes(expression); } </msxsl:script> However, I need to run the equivalent f...more >>

XmlValidating Reader and XmlNodes
Posted by Todd Bright at 3/24/2005 9:19:02 AM
Is there a way to get the current XmlNode from the reader while in the validation event handler? What I'd like to do is display the error message along with the name of its parent node. In my XML format, there are parent nodes named differently with some of the same names for child nodes...more >>

Can't get XSLT document() function to work - depends on ORDER of execution
Posted by David Laub at 3/24/2005 8:57:15 AM
My issues appear to have nothing to do with XMLResolver directly - If I run multiple transforms in a single dot net app, the transform with the document() call will fail if it is run LAST - if the identical transform with the document() is run FIRST, it runs fine! ...more >>

XML Class and Node InsertAfter
Posted by Kael at 3/24/2005 5:49:02 AM
Hi, I’ve made a class to help me accomplish some things faster but I’m having problems inserting nodes. I’ve tried many different ways, but with no success. This is a very stripped down version of what I’m trying to do. I know that I’m simply missing some basic understanding, so ho...more >>

Some basic questions about XML
Posted by Tony Johansson at 3/23/2005 4:44:27 PM
Hello I'm trying to learn XML by reading a book. There is some text in the book that I don't understand so I try to ask you out there. My first question is does this statement mean that the character string from is placed into the attribute with name type <contect type = "from"> Wh...more >>

Can't get XSLT document(0 funnction to work at all in dot net
Posted by David Laub at 3/23/2005 1:58:37 PM
* I've been spinning my wheels for a day on this. * At first I thought I have a relative path issue with the doucument, but using XmlUrlResolver in the transform made no difference * Hard coded a full path, e.g. document('C:\CollisionFoTest\CollisionData.xml') also made no difference * Using al...more >>

Including HTML Tags in XML Text
Posted by Rick at 3/23/2005 9:35:14 AM
I am fairly new to XML, I have an XML document that holds configurations for an ASP.NET application, within the configuration XML File I have a line of text that will feed into a lable on a web form. I would like to be able to include html breaks <BR> within the text. Is this possible and if...more >>

Removing namespace declaration on a node
Posted by Manoj G at 3/23/2005 7:57:04 AM
Hello, I believe there is no way to remove the default namespace declaration (For eg <DataSet xmlns="something">.... ) on an XmlNode object directly through DOM. So, what is the best way to remove it 1) XSLT templates? 2) Copy all the contents into a new node and leave out the namespace...more >>

catching exception from pIXMLHTTPRequest object
Posted by Joe at 3/23/2005 12:00:00 AM
Hi, I am having a problem with the following code. When there is an exception happen inside the ¡§pIXMLHTTPRequest->send(var)¡¨ the ¡§GetLastError()¡¨ return 0 which means no error. How can I get more information regarding all the exception happened inside the ¡§pIXMLHTTPRequest-...more >>

MSXML6
Posted by nospam NO[at]SPAM devdex.com at 3/22/2005 11:56:07 PM
Hey, I was looking at the MS tool VersionCheck and it indicated that I did not have MSXML6. My searching for this file has been fruitless. The only place that I could find it was on a site that required Paypal to download (Checked source code of web page prior to submitting). I do not ...more >>

Shell Game with XML Attributes
Posted by AJ at 3/22/2005 8:25:57 PM
I have a problem that I suspect shouldn't be this hard to figure out, but I'm a .NET newbie so I'm looking for help. I am reading from an XML file to populate a combo box with the value of an "Name" attribute to several elements. When the user selects an item from the combo and clicks a comma...more >>

Exception: "Index was outside the bounds of the array." in a XSLT transformation.
Posted by David Laub at 3/22/2005 4:36:21 PM
A transform that works fine in XMLSPy fails when I run it under dot net. I've run many other transforms successfully in dot net so there is something "special" about this transform I just installed dot net framework 1.1 SP1 - but I still get the same error What makes this transform more comple...more >>

Going from string variable containing XML to object
Posted by SA at 3/22/2005 2:03:47 PM
Hi all, I have a string that contains XML content (and also an XmlDocument object). I need to "deserialize" that XML into an object of a known type. Right now, the only way I have found is to create a memory stream, write the XmlDocument object to that MemoryStream using an XmlWriter and t...more >>

Getting Rows
Posted by Yama at 3/22/2005 12:31:03 PM
Hi, I am really confused. I have created a strong typed dataset for Northwind database Customer table. Now I am loading it with a stream of XML (ADO style) with the following: Customers _cust = new Customers(); XmlTextReader xmlReader = new XmlTextReader(stream); stream.Position = 0; ...more >>

correct use of "default" attribute in XML Schema
Posted by Stefano at 3/22/2005 9:49:33 AM
Hi all, what is the correct use of the "default" attribute in XML Schema? For example: <xs:element name="myProperty" type="xs:string" default="myDefaultValue"/> What can I do with it? What is the meaning of < ....default="myDefaultValue" /> ? Thank you so much. Bye -- Stefano G...more >>

Getting an integer value (in one line) out of SelectSingleNode from an XMLDoc.
Posted by Sashi at 3/21/2005 11:43:35 PM
[C# code oriented] Two questions: (1) I can pull the text of an XML element as a string just fine using code as such: strSomeString = myXmlDoc.SelectSingleNode("/Element1/Element2/Element3[1]", myXmlNSMgr).InnerText; However, the text to be found there is an integer number. I have t...more >>

Accessing DataSet
Posted by Yama at 3/21/2005 5:49:02 PM
Hi, I have the following loaded into a dataset: <xml version="1.0" encoding="UTF-16"> <xml xmlns:s="uuid:BDC6E3F0-6DA3-11d1-A2A3-00AA00C14882" xmlns:dt="uuid:C2F41010-65B3-11d1-A29F-00AA00C14882" xmlns:rs="urn:schemas-microsoft-com:rowset" xmlns:z="#RowsetSchema"> <s:S...more >>

DOCTYPE with Xml Serialization
Posted by Vlad at 3/21/2005 5:48:09 PM
I have a class that serialize using the XmlSerializer. I am using several attributes for class members to control serialization process. One thing I cannot figure out how to do is how to add DOCTYPE attribute to the file. This XML file must use the doctype that refers to the DTD rather than an ...more >>

XML Encoding question (C#)
Posted by Mike at 3/21/2005 4:49:03 PM
Hi! I have the following problem: I am getting an XML file from a 3rd party. The encoding on the XML file is encoding="utf-8" I have no control over generation of this file. This file is produced by a Lotus Notes system and often has illegal characters embedded to it. Of course the .NET ...more >>

XPath GetAttributes Problem
Posted by yonta via .NET 247 at 3/21/2005 12:49:26 PM
Hi I need to select several nodes (title) on an xml document based on an atrribute(user) and then read from each selected element (title) another attribute(nomequiz). Here's my code so far but it isn't working.. Would really appreciate some help. Got really stuck. I already tried with xmlDo...more >>

Should System.Xml.NameTable be deprecated?
Posted by Mark Bosley at 3/21/2005 12:21:54 PM
There seems to be little interest in this object, the docs are wrong and it doesn't do much. Two years ago, it was pointed out that the documentation is nonsensical (http://groups-beta.google.com/group/microsoft.public.dotnet.framework/browse_thread/thread/3e621115f78943e2/38232c4e9c0bdd64?q=M...more >>

SoapExtensions & RequestSoapContext
Posted by Manoj G at 3/21/2005 10:31:04 AM
Hello, I was working with WSE & SoapExtensions and I realized something subtle, but could be an issue to consider. Using the SoapExtensions, I alter the contents of the SOAP message before the deserialization happens on the server. Now, in my web method, if I check the contents of the e...more >>

XSD - How to create a default XML
Posted by Stefano at 3/21/2005 9:40:08 AM
Hi all, I defined a XML Schema... so I've a .xsd file. I defined the schema using "default" attribute... for example: <xs:element name="color" type="xs:string" default="red"/> Now, I would like to generate an empty XML file, from the XML Schema. How can I do that? Thanks a lot. By...more >>

How to keep XSLs in Memory?
Posted by Alexis at 3/21/2005 6:59:04 AM
Hello, I'm working on a project that uses over a hundred XLSs for transforming xml documents. The project consists of several webservices (IIS) calling a few dlls. This dlls make the business logic and are the ones that do the transformation, so the XLSs are used by these dlls. Right now we...more >>

view xml from web in a datagrid
Posted by Mike & Dyan at 3/20/2005 1:27:45 AM
I would like to go to this web address http://setiathome2.ssl.berkeley.edu/classpages/days/2452829.html and be able to pull the info off of it and display it in a datagrid. I am assuming that I will have to put the info into a dataset to be able to view the info in the datagrid. At least poi...more >>

Exception on XmlDocumet.Load()
Posted by Chris at 3/20/2005 12:00:00 AM
Hi, I have xml files which contain a <!DOCTYPE> with a link to a dtd. On my local computer this this link is invalid as it refers to a folder that does not exist. The link has the format "file://localhost...". Using an System.Xml.XmlDocument object and calling the Load() function, the pars...more >>


DevelopmentNow Blog