November 24th, 2008, 11:11 AM
Validating XML - Best practice
C#, VS 2005, .net 2.0
Hi, I am passing an xml file to my program, which I validate against 2 schemas.
I have one main schema, which uses a second schema by means of the import statement.
Both schemas are in the same directory, and the validation works well in C# when I hardcode the schema locations.
However, I would like to embed my schemas in my project and validate without depending on external files. When I try this, it doesnt work. The main schema has an import statement like:
<import namespace "http://www.opengis.net/gml" schemaLocation="gmlschema"/>
But I embed both schemas, rather than using file system, it doesnt work. Any suggestions?
Click Here to Expand Forum to Full Width
This is a Codeguru.com survey!