Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Deserialization Failure on WCF Service
Message
De
24/02/2011 07:08:50
 
 
À
Tous
Information générale
Forum:
ASP.NET
Catégorie:
Windows Communication Foundation (WCF)
Titre:
Deserialization Failure on WCF Service
Versions des environnements
Environment:
C# 4.0
Divers
Thread ID:
01501583
Message ID:
01501583
Vues:
1153
Hi,

I'm using a RIA Services class library. Trying to track down a problem I have this simple method on the Service:
[Invoke]
        public string Echo(string s)
        {
            //Uri uri = System.ServiceModel.OperationContext.Current.IncomingMessageHeaders.To;
            //return uri.AbsoluteUri;
            return s == string.Empty ? "Empty String" : s;
        }
which is generated on the client like so:
public InvokeOperation<string> Echo(string s)
        {
            Dictionary<string, object> parameters = new Dictionary<string, object>();
            parameters.Add("s", s);
            this.ValidateMethod("Echo", parameters);
            return ((InvokeOperation<string>)(this.InvokeOperation("Echo", typeof(string), parameters, true, null, null)));
        }
When calling this from an IE based Silverlight application I get an error on the server:
"Error in deserializing body of request message for operation 'Echo'. The OperationFormatter could not deserialize any information from the message because the Message is empty (IsEmpty=true)."
In an attempt to find I more I ran Fiddler on the client side. But with Fiddler in between it works. I then found this:
http://charliedigital.com/category/wcf/ (the IE7,AJAX, and 400 "Bad Request" part)
Not the same scenario but the same symptoms (I also verified that it works using FireFox)
FWIW all Invoke operations that pass parameters to the server suffer from this problem whilst IEnumerable queries which take parameters are fine.
Anyone know why IE is exibiting this problem ?
Répondre
Fil
Voir

Click here to load this message in the networking platform