Tuesday, June 04, 2002

I was considering a possible answer to Justin's problem with validating non-namespaced documents.  It seemed like I could load an XmlReader with the document in question, then read the root <rss> element, check the version attribute, and at that point load the correct schema, create an XmlValidatingReader around the XmlReader, and go.  No dice.  It seems that you can't load a schema partway through the validation process, not that validation fails, but that invalid documents don't.  The best workaround I could think of was to create 2 XmlReader objects, use the first one to peek at the version, then create an XmlValidatingReader around the 2nd.  I'm sure this is lighter weight than creating an entire XmlDocument and then an XmlNodeReader around the document, but not as clean as I'd hoped could be the case.
7:02:36 PM  permalink Click here to send an email to the editor of this weblog. 

Welcome Greg Reinacker to the weblog neighborhood!

Greg is leaving Galileo June 14, and we'll all miss him.  Greg was our resident COM and Windows security expert, among other things.  Last I heard, he's still looking for his next gig, so if you're in the Denver area and need a Windows guru, look him up!

10:34:56 AM  permalink Click here to send an email to the editor of this weblog. 


Stories
DateTitle
1/23/2003 Why XML?
8/13/2002 Resolution for IE and Windows problems
8/10/2002 Supporting VS.NET and NAnt
5/11/2002 When do you stop unit testing?
Contact
jabber: weakliem
YM: gweakliem
MSN: gweakliem@pcisys.net
email: Click here to send an email to the editor of this weblog.
Subscribe to "Gordon Weakliem's Weblog" in Radio UserLand.
Click to see the XML version of this web page.