Wrox Programmer Forums
Go Back   Wrox Programmer Forums > XML > XML
|
XML General XML discussions.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the XML section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old November 1st, 2005, 10:43 PM
zas zas is offline
Registered User
 
Join Date: Nov 2005
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default xsd:restriction

I am wondering if someone can help with this rather small issue.

I have and xsd file which gets read and recreated based on changes in data. Following is the snippet

<xsd:simpleType name="stype_abc"> //line 1
    <xsd:restriction base="xsd:string"> //line 2
      <xsd:enumeration value="xxxxxxx" form:text="xxxxxx" />
    ...
    ...
    </xsd:restriction>
</xsd:simpleType>

when the code is run which is:

XmlNode restrictionNode = schemaDocument.SelectSingleNode("//xsd:simpleType[@name='stype_abc']/xsd:restriction", nsManager);
restrictionNode.RemoveAll();
// this is removing all existing data under that node.

I get everthing correct except in the new file the line 2 is missing base="xsd:string" which creates some problems. I guess the obviuos question is what code changes I need to make to retain base="xsd:string" so the line 2 look like <xsd:restriction base="xsd:string">

Thanx





Similar Threads
Thread Thread Starter Forum Replies Last Post
XSD.EXE Gen’d C# Deserializing w/ .xsd Subst Group greenstone XML 0 November 9th, 2007 09:27 PM
Restriction to certain applications PankajGarg10 General .NET 0 April 13th, 2007 01:08 AM
Merging XSD files in one XSD file by using what? haoxuqian XML 1 November 4th, 2005 01:42 PM
Search restriction Snib Forum and Wrox.com Feedback 0 August 13th, 2004 11:02 AM
By pass Scripting Restriction hrishimusale HTML Code Clinic 2 July 18th, 2004 11:48 PM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.