Hello,

I was just playing around with XML serialization and noticed that I
couldn't map a schema nonNegativeInteger type to an int32 field in my .NET
type.  Sure enough, the docs show that nonNegativeInteger,
nonPositiveInteger, positiveInteger, negativeInteger, and a few
other "whole number" types are mapped to System.String.

Does anyone know the rationale for this?  Is there a way to tell the
default serializer to allow this (I guess I could just remove the
attribute's DataType property):

[System.Xml.Serialization.XmlElementAttribute
(DataType="nonNegativeInteger", IsNullable=true)]
public int PurchaseLeadTime;

Thanks,

- EJ

===================================
This list is hosted by DevelopMentorŪ  http://www.develop.com
Some .NET courses you may be interested in:

NEW! Guerrilla ASP.NET, 26 Jan 2004, in Los Angeles
http://www.develop.com/courses/gaspdotnetls

View archives and manage your subscription(s) at http://discuss.develop.com

Reply via email to