NullReferenceException during ReadXml

Posts   
 
   
 
Anonymous
User
Posts: 0
Joined: 11-Nov-2006
# Posted on: 17-Jun-2010 12:07:53   

I'm using LLBLGen 2.6, my version of the ORMSupportClasses is 2.6.08.0804.

When calling ReadXml to deserialize from an XML file created by the same application, I get the following exception


System.NullReferenceException occurred
  Message="Object reference not set to an instance of an object."
  Source="SD.LLBLGen.Pro.ORMSupportClasses.NET20"
  StackTrace:
       at SD.LLBLGen.Pro.ORMSupportClasses.XmlHelper.XmlValueToObject(String typeName, String xmlValue)
       at SD.LLBLGen.Pro.ORMSupportClasses.EntityBase2.Xml2Entity(XmlNode node, Dictionary`2 processedObjectIDs, List`1 nodeEntityReferences)
       at SD.LLBLGen.Pro.ORMSupportClasses.EntityBase2.ReadXml(XmlNode node, XmlFormatAspect format)
       at SD.LLBLGen.Pro.ORMSupportClasses.EntityBase2.ReadXml(String xmlData)
       at MyApp.GetFiles(String path) in C:\myapp\FileManager.vb:line 203
  InnerException: 

This happens since we upgraded from 2.0 to 2.6. Is there any other things that we need to check that might have been forgotten in the upgrade? What can I do to solve this issue?

(I've read http://www.llblgen.com/tinyforum/Messages.aspx?ThreadID=7961&StartAtMessage=0 that's why I tend to believe some part of the upgrade process might have been missed)

MTrinder
User
Posts: 1461
Joined: 08-Oct-2008
# Posted on: 17-Jun-2010 21:16:01   

Are you sure that the 2.6 code has been generated into a clean folder structure -ie that there are no remnants of the 2. code remaining...?

Matt

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39614
Joined: 17-Aug-2003
# Posted on: 17-Jun-2010 21:21:27   

Also try the latest runtime build for v2.6, yours is very old

Frans Bouma | Lead developer LLBLGen Pro
Anonymous
User
Posts: 0
Joined: 11-Nov-2006
# Posted on: 18-Jun-2010 03:21:25   

MTrinder wrote:

Are you sure that the 2.6 code has been generated into a clean folder structure -ie that there are no remnants of the 2. code remaining...?

Matt

Well no it wasn't, we have tons of user regions with specific code in the generated code, so I had to regenerate over the existing classes. Do you have anything specific in mind that I need to clean up?

daelmo avatar
daelmo
Support Team
Posts: 8245
Joined: 28-Nov-2005
# Posted on: 18-Jun-2010 03:52:57   

Silvermist wrote:

MTrinder wrote:

Are you sure that the 2.6 code has been generated into a clean folder structure -ie that there are no remnants of the 2. code remaining...?

Matt

Well no it wasn't, we have tons of user regions with specific code in the generated code, so I had to regenerate over the existing classes. Do you have anything specific in mind that I need to clean up?

It's just to check that everything in migration is ok. You should regenerate in an empty folder just to discard this problem.

And of course, please use the latest v2.6 runtime library version.

David Elizondo | LLBLGen Support Team
Anonymous
User
Posts: 0
Joined: 11-Nov-2006
# Posted on: 23-Jun-2010 10:49:32   

Otis wrote:

Also try the latest runtime build for v2.6, yours is very old

Thanks a bunch Frans, that did the trick. This problem is now solved.