NullReference Exception (WebService)

Posts   
 
    
Rushmore
User
Posts: 125
Joined: 27-Jan-2005
# Posted on: 08-Aug-2006 15:30:00   

Hello,

I am a little bit distressed. I have generated a WebService to handle my database access from a desktop and mobile device application. Everything works fine. But for now I get a "NullReference" exception, but only on my mobile device:

System.NullReferenceException wurde nicht behandelt. Message="NullReferenceException" StackTrace: bei SD.LLBLGen.Pro.ORMSupportClasses.EntityBase2.Xml2Entity() bei SD.LLBLGen.Pro.ORMSupportClasses.EntityBase2.ReadXml() bei SD.LLBLGen.Pro.ORMSupportClasses.EntityBase2.ReadXml() bei System.Xml.Serialization.XmlSerializationReader.DeserializeSerializableElement() bei System.Xml.Serialization.XmlSerializationReader.deserializeElement() bei System.Xml.Serialization.XmlSerializationReader.DeserializeElementMember() bei System.Xml.Serialization.XmlSerializationReader.deserializeMembers() bei System.Xml.Serialization.XmlSerializationReader.DeserializeComplexElement() bei System.Xml.Serialization.XmlSerializationReader.deserializeElement() bei System.Xml.Serialization.XmlSerializationReader.DeserializeElementMember() bei System.Xml.Serialization.XmlSerializationReader.deserializeMembers() bei System.Web.Services.Protocols.SoapMessageParser.execute() bei System.Web.Services.Protocols.SoapMessageSerializer.Deserialize() bei System.Web.Services.Protocols.SoapHttpClientProtocol.doInvoke() bei System.Web.Services.Protocols.SoapHttpClientProtocol.Invoke() bei MobileOffice.Web.Service.GetCurrentMandator() bei MobileOffice.BL.Generic.get_Mandant() bei MobileOffice.UI.Leistungserfassung.Zusatzleistung.InitEntity() bei MobileOffice.UI.Leistungserfassung.Zusatzleistung.cboLeistung_KeyPress()

here is the generated and (modified disappointed ) code from the reference.cs:


        [System.Web.Services.Protocols.SoapDocumentMethodAttribute("http://tempuri.org/GetCurrentMandator", RequestNamespace="http://tempuri.org/", ResponseNamespace="http://tempuri.org/", Use=System.Web.Services.Description.SoapBindingUse.Literal, ParameterStyle=System.Web.Services.Protocols.SoapParameterStyle.Wrapped)]
        public MandantenstammEntity GetCurrentMandator() {
            object[] results = this.Invoke("GetCurrentMandator", new object[0]);
            return ((MandantenstammEntity)(results[0]));
        }
        
        /// <remarks/>
        public System.IAsyncResult BeginGetCurrentMandator(System.AsyncCallback callback, object asyncState) {
            return this.BeginInvoke("GetCurrentMandator", new object[0], callback, asyncState);
        }
        
        /// <remarks/>
        public MandantenstammEntity EndGetCurrentMandator(System.IAsyncResult asyncResult) {
            object[] results = this.EndInvoke(asyncResult);
            return ((MandantenstammEntity)(results[0]));
        }

Last week it was still working confused

Regards, Carlo

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39927
Joined: 17-Aug-2003
# Posted on: 08-Aug-2006 15:54:13   

Please state: llblgen pro version, build date of runtime libs etc.

Frans Bouma | Lead developer LLBLGen Pro
Rushmore
User
Posts: 125
Joined: 27-Jan-2005
# Posted on: 08-Aug-2006 16:06:44   

Otis wrote:

Please state: llblgen pro version, build date of runtime libs etc.

LLBLGen Pro. Version 1.0.2005.1 Final (February 9th, 2006) SD.LLBLGen.Pro.ORMSupportClasses.CF11.dll (1.0.2005.1, 11.02.2006)

Regards, Carlo

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39927
Joined: 17-Aug-2003
# Posted on: 08-Aug-2006 16:45:33   

Could you try with the latest runtime library builds for 1.0.2005.1 please?

Frans Bouma | Lead developer LLBLGen Pro
Rushmore
User
Posts: 125
Joined: 27-Jan-2005
# Posted on: 08-Aug-2006 17:24:27   

It´s the same behaviour. Any other suggestions?

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39927
Joined: 17-Aug-2003
# Posted on: 08-Aug-2006 18:01:25   

This happens on CF.NET 1.0? What has changed since the last time it did work?

Frans Bouma | Lead developer LLBLGen Pro
Rushmore
User
Posts: 125
Joined: 27-Jan-2005
# Posted on: 08-Aug-2006 23:27:25   

I´m using CF 2.0. I´ve changed nothing (as far as I know sunglasses )

Research to be continued ...

Rushmore
User
Posts: 125
Joined: 27-Jan-2005
# Posted on: 09-Aug-2006 14:08:46   

I have found the problem: simple_smile

The generated DAL-Code was out of sync (DAL Desktop/DAL PPC) I´m not sure wich devil has generated the code only for the desktop (maybe me, myself and I flushed )

Regards, Carlo