vb.net - Cannot upload a file through webservice that is over 1MB -


could take @ web.config , tell me wrong it? not able upload file through remote webservice larger 1mb. guessing has attribute settings, far havent had luck changing values. or setting on host server side can't override?

     <?xml version="1.0"?>     <configuration>       <appsettings>         <add key="categorypath" value="qa/processvalidation"/>       </appsettings>       <startup>         <supportedruntime version="v4.0" sku=".netframework,version=v4.5"/>       </startup>       <system.servicemodel>         <bindings>           <basichttpbinding>             <binding name="basichttpbinding_authentication" closetimeout="00:01:00" opentimeout="00:01:00" receivetimeout="00:10:00" sendtimeout="00:01:00" allowcookies="false" bypassproxyonlocal="false" hostnamecomparisonmode="strongwildcard" maxbuffersize="65536" maxbufferpoolsize="524288" maxreceivedmessagesize="65536" messageencoding="text" textencoding="utf-8" transfermode="buffered" usedefaultwebproxy="true">               <readerquotas maxdepth="32" maxstringcontentlength="8192" maxarraylength="16384" maxbytesperread="4096" maxnametablecharcount="16384"/>               <security mode="none">                 <transport clientcredentialtype="none" proxycredentialtype="none" realm=""/>                 <message clientcredentialtype="username" algorithmsuite="default"/>               </security>             </binding>             <binding name="basichttpbinding_documentmanagement" closetimeout="00:01:00" opentimeout="00:01:00" receivetimeout="00:10:00" sendtimeout="00:01:00" allowcookies="false" bypassproxyonlocal="false" hostnamecomparisonmode="strongwildcard" maxbuffersize="65536" maxbufferpoolsize="524288" maxreceivedmessagesize="65536" messageencoding="text" textencoding="utf-8" transfermode="buffered" usedefaultwebproxy="true">               <readerquotas maxdepth="32" maxstringcontentlength="8192" maxarraylength="16384" maxbytesperread="4096" maxnametablecharcount="16384"/>               <security mode="none">                 <transport clientcredentialtype="none" proxycredentialtype="none" realm=""/>                 <message clientcredentialtype="username" algorithmsuite="default"/>               </security>             </binding>             <binding name="basichttpbinding_contentservice" closetimeout="00:01:00" opentimeout="00:01:00" receivetimeout="00:10:00" sendtimeout="00:01:00" allowcookies="false" bypassproxyonlocal="false" hostnamecomparisonmode="strongwildcard" maxbuffersize="65536" maxbufferpoolsize="524288" maxreceivedmessagesize="65536" messageencoding="mtom" textencoding="utf-8" transfermode="buffered" usedefaultwebproxy="true">               <readerquotas maxdepth="32" maxstringcontentlength="8192" maxarraylength="16384" maxbytesperread="4096" maxnametablecharcount="16384"/>               <security mode="none">                 <transport clientcredentialtype="none" proxycredentialtype="none" realm=""/>                 <message clientcredentialtype="username" algorithmsuite="default"/>               </security>             </binding>           </basichttpbinding>         </bindings>         <client>         </client>       </system.servicemodel>       <system.web>         <compilation debug="true"/>       </system.web>     </configuration> 

edit: have no control service on server side, using wcf , have links them.

it's not entirely clear whether config file posted client config or server config, i'm going make semi-educated guess , it's client config, , you're using client connect third-party service.

without knowing error message and/or behavior you're seeing, or how you're creating client in code, there few things can try:

  1. increase size of maxstringcontentlength attribute in <readerquotas> element. right set default of 8,192 bytes.
  2. if service config, increase maxreceivedmessagesize attribute in <binding> element - right set default of 65536.

the maximum value both of these attributes int32.maxvalue - 2gb. in either case, unless have endpoint specified in config file (which don't appear currently) references defined binding config (via <endpoint> element's bindingconfiguration attribute), default values endpoint's binding.

so need either make binding definition default (by omitting name attribute <binding> element, or need assign binding configuration want use using bindingconfiguration attribute on endpoint, this:

<endpoint address="" binding=basichttpbinding"           bindingconfiguration="mybinding" contract="myservice.imyservice" /> 

if service not under control, not able if have low limits set, client cannot modify service's configuration (and service cannot modify client's either). configurations separate, many parts (binding, security, etc) have match.

if above doesn't help, please edit question add more info (what error message/behavior seeing, client or service config, how creating client, have service config, etc).


Comments

Popular posts from this blog

javascript - RequestAnimationFrame not working when exiting fullscreen switching space on Safari -

Python ctypes access violation with const pointer arguments -