Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Loading dataset from XML with Schema
Message
 
 
To
17/03/2010 15:35:45
General information
Forum:
ASP.NET
Category:
XML
Environment versions
Environment:
C# 2.0
Miscellaneous
Thread ID:
01454990
Message ID:
01455215
Views:
36
>>The dataset initially is created empty (as you could see from the code above). Then by reading the xml schema (from .xsd file) the dataset data types are defined. Then the XML is read into the dataset. So I don't see where a NULL value would get there.
>
>This syntax should be accepted. I cannot see what is conflicting. Try 0 instead of false. That should also be supported. Or, if this is the default, maybe you do not need to put it.

I changed the default value in XSD file to "0" instead of "false" and still a problem if the entry in this element in the XML file is empty. You see, I am trying prevent an error when reading this XML if user leaves one of the elements entry empty. This element should be loaded in the dataset as a Boolean datatype. And as I said, I thought that if I specify a default in the schema file (.XSD) .NET would simply load the existing XML setting the value to this Boolean type field as default specifies (false or true). I understand what you are saying that maybe the entry should be 0 but I need to work against empty or any entry.

Thank you.
"The creative process is nothing but a series of crises." Isaac Bashevis Singer
"My experience is that as soon as people are old enough to know better, they don't know anything at all." Oscar Wilde
"If a nation values anything more than freedom, it will lose its freedom; and the irony of it is that if it is comfort or money that it values more, it will lose that too." W.Somerset Maugham
Previous
Reply
Map
View

Click here to load this message in the networking platform