Avatar of srussell705
srussell705

asked on 

WCF IIS6 VS2008 (405) Method Not Allowed error

I have an inhouse WCF / ASP.NET page combination.  in my unit tests my method called works fine.  When i call same method from ASP.NET with same data, i get this error:
The remote server returned an error: (405) Method Not Allowed.

[WebException: The remote server returned an error: (405) Method Not Allowed.]
   System.Net.HttpWebRequest.GetResponse() +2060853
   System.ServiceModel.Channels.HttpChannelRequest.WaitForReply(TimeSpan timeout) +54

[ProtocolException: The remote server returned an unexpected response: (405) Method Not Allowed.]
   System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg) +7605567
   System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type) +257
   Mimeo.Services.Enterprise.ProductionService.ProductionShippingServiceContract.PostLogicorXML(String PacklistBarcode, String LPN, Decimal Weight) +0
   Mimeo.Services.Enterprise.ProductionService.ProductionShippingServiceClient.PostLogicorXML(String PacklistBarcode, String LPN, Decimal Weight) in C:\TFS\Tools\Production Tools\rename-SR\myVPCServiceContracts\Proxies\LogicorShippingServiceClient.cs:67
   Mimeo.Tools.ShippingTools.Shippingtools2.Button1_Click(Object sender, EventArgs e) in C:\TFS\Tools\Production Tools\rename-SR\ShippingToolsAJAX\ShippingToolsAJAX\Shippingtools2.aspx.cs:30
   System.Web.UI.WebControls.Button.OnClick(EventArgs e) +111
   System.Web.UI.WebControls.Button.RaisePostBackEvent(String eventArgument) +110
   System.Web.UI.WebControls.Button.System.Web.UI.IPostBackEventHandler.RaisePostBackEvent(String eventArgument) +10
   System.Web.UI.Page.RaisePostBackEvent(IPostBackEventHandler sourceControl, String eventArgument) +13
   System.Web.UI.Page.RaisePostBackEvent(NameValueCollection postData) +36
   System.Web.UI.Page.ProcessRequestMain(Boolean includeStagesBeforeAsyncPoint, Boolean includeStagesAfterAsyncPoint) +1546

I can see from Line # 30 that my button click passes the params back to the WCF service.  Then these 2 lines are trying to deal with it:
 System.Runtime.Remoting.Proxies.RealProxy.HandleReturnMessage(IMessage reqMsg, IMessage retMsg) +7605567
   System.Runtime.Remoting.Proxies.RealProxy.PrivateInvoke(MessageData& msgData, Int32 type) +257

I am expectin bool back.

What have i missed in either a configuration of IIS  or some other space?

TIA

__Stephen

Web ServicesWeb Applications

Avatar of undefined
Last Comment
srussell705

8/22/2022 - Mon