XML not loaded, without errors

Apr 12, 2011 at 11:32 AM

I used xsd2code in vb.net project, on an XSD.Exe generated xsd. I wanted to move my XML code to a C# dll.

I tried to regenerate the source code (I'm not sure I'm using the same xsd than before, or a new generated one). After setting the right XmlRootAttribute, I can use LoadFromFile, but nothing is loaded. I get an empty object.

I can't find what I have done wrong... How can I debug this thing ?

May 12, 2011 at 11:23 AM

I had the exact same problem using version 3.4.0.38967 of the utility.  When I set the GenerateXmlAttributes property to true when generating my class, the utility worked much better.

Coordinator
May 19, 2011 at 9:12 PM

Please try xsd2Code 3.5Beta and set GenerateOderAttribute to false.

http://xsd2code.codeplex.com/releases/view/39563

Pascal.

May 20, 2011 at 3:50 AM

KingJ's solution worked.

I'll try the beta sometimes, but I already lost too much time on juste this code move :)

May 21, 2011 at 10:59 AM
Edited May 22, 2011 at 7:48 AM

So, I was in fact missing an element (its value was never read...)

I installed the 3.5 Beta, check that GenerateOderAttribute was set to false, and it worked perfectly !

(EDITED : minor problem was my problem :) )