.NET Tutorials, Forums, Interview Questions And Answers
Welcome :Guest
Sign In
Win Surprise Gifts!!!

Top 5 Contributors of the Month
Gaurav Pal
Post New Web Links

how do i set maxReceivedMessageSize

Posted By:      Posted Date: April 14, 2011    Points: 0   Category :SharePoint

How do i set maxReceivedMessageSize property in app.config file. Here is my config file. What am i doing wrong here???

    <binding name="myBinding" maxReceivedMessageSize="400000"/>

View Complete Post

More Related Resource Links

maxReceivedmessageSize exception is not logged.

HI all,   we have wcf service deployed to production, and we have implemented the interface IErrorHandler to log events into eventvwr when ever an exception is raised in a service method, all is well and its working fine, but all of a sudden we are getting that method "xyz has failed, so i went into the event log to see that exception "nothing was logged" so out of curisoity i turned on tracing and i see the error  that the maxreceived message size has excedded, so i changed the config and everything is working as expected. Note: We use IIS to host this service the issue: why dint wcf log this message and what changes do i need to make so that these kind of errors are logged somewhere your help is appreciated. Thanks -nen  

Compact Framework - MaxReceivedMessageSize property


I am using Microsoft Synchronization services to synchronize a SQL Server Compact Edition database with a SQL Server 2008 database. I used the netcfSvcUtil.exe tool to generate the wcf service the mobile client will use to connect to the server.

The client uses a basicHttpBinding, which is required for WCT on the compact framework. The synchronization works fine for small amounts of data. When I try to synchronize larger amounts of data I receive an exception with the following message on the client:

"The maximum message size quota for incoming messages(65536) has been exceeded. To increase the quota, use the MaxReceivedMessageSize property on the appropriate binding."

It took a while but I figured out how and where to change this on the client. In MyServiceClientContract I change the binding as it is created:

   Public Shared Function CreateDefaultBinding() As
       Dim binding As System.ServiceModel.Channels.CustomBinding =
New System.ServiceModel.Channels.CustomBinding

problem with MaxReceivedMessageSize


Hi, I have a application set up that works for normal sized messages, but gives the following exception when trying to send a message

( after xml serialisation, the message appears to be 307KB)

---> System.ServiceModel.QuotaExceededException: The maximum message size quota for incoming messages (65536) has been exceeded. To increase the quota, use the MaxReceivedMessageSize property on the appropriate binding element.

As far as i can see, all my size settings in de web.config ( serverside) and appconfig ( client side ) are maxed out.

the error only occurs when sending the 307KB message from client to server, when retrieving the exact message (from a get operation : server to client), then no error occurs, so i assume the app.config file is correct.


  <serviceHostingEnvironment multipleSiteBindingsEnabled="true" 

WCF Service hosted inside SharePoint 2010's ISAPI folder and MaxReceivedMessageSize


I got a WCF service hosted inside the SharePoint 2010 following this article http://answers.oreilly.com/topic/1404-how-to-customize-wcf-services-in-sharepoint-2010/

Everything was going great until I wanted to increase the MaxReceivedMessageSize however there is no configuration file for this service.

I tried to add a configuration file to be deployed along with the svc service in the same directory inside the ISAPI mapped folder but I get this error:

The service '/_vti_bin/epcc/messagesarchive/contactssearcher.svc' cannot be activated due to an exception during compilation.  The exception message is: Could not find a base address that matches scheme http for the endpoint with binding BasicHttpBinding. Registered base address schemes are []..

Here is my configuration,

   <service name="WCFServices.ContactsSearcher.ContactsSearcher" behaviorConfiguration="ContactsSearcherBehavior">
    <endpoint address="ContactsSearcher"
    <endpoint address="mex"

MaxReceivedMessageSize and maxStringContentLength


Hi all,

I was wondering how the following two properties are related to eachother:

  • MaxReceivedMessageSize
  • maxStringContentLength

The MaxReceivedMessageSize Gets or sets the maximum size for a message that can be received on a channel configured with this binding. So this settings is representing how big the message could be in bytes, based on the current binding.

The maxStringContentLength is a positive integer that specifies the maximum characters allowed in XML element content. The default is 8192.

Raising the MaxReceivedMessageSize without raising the maxStringContentLength could give you some problems, right? When do you want to raise only the maxreceivedmessagesize without raising the maxStringContentLength?

Thanks in advance!




WCF Test Client - increasing MaxReceivedMessageSize



I am using the WCF Test Client that ships with Visual Studio 2010 to test my WCF service.  However, i am getting the error" The maximum message size quota for incoming messages (65536) has been exceeded" after using the WCF Test Client utility to invoke a method on my service.

I know how to configure a service to increase MaxReceivedMessageSize by configuring a binding configuration, but how can i increase the MaxReceivedMessageSize of the WCF Test Client itself that ships with VS2010?

Thanks for any help

ASP.NetWindows Application  .NET Framework  C#  VB.Net  ADO.Net  
Sql Server  SharePoint  Silverlight  Others  All   

Hall of Fame    Twitter   Terms of Service    Privacy Policy    Contact Us    Archives   Tell A Friend