Hi,
I developed a web application and wcf services. I added wcf reference to web application.After executing the project,it shows error like,
There was no endpoint listening at http://localhost:3331/Service1.svc that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details.
Please give me any suggestions...
This is the web.config on the WCF client project:
<!--
For more information on how to configure your ASP.NET application, please visit
http://go.microsoft.com/fwlink/?LinkId=169433
-->
<configuration>
<connectionstrings>
<add name="ApplicationServices" connectionstring="data source=.\SQLEXPRESS;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|\aspnetdb.mdf;User Instance=true" providername="System.Data.SqlClient">
<add name="FirstGuardianConnectionString" connectionstring="Data Source=SYSTEM1;Initial Catalog=FirstGuardian;User ID=sa" providername="System.Data.SqlClient">
<system.web>
<compilation debug="true" targetframework="4.0">
<assemblies>
<add assembly="System.Data.Linq, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089">
<authentication mode="Forms">
<forms loginUrl="~/Account/Login.aspx" timeout="2880"/>
<membership>
<providers>
<clear>
<add name="AspNetSqlMembershipProvider" type="System.Web.Security.SqlMembershipProvider" connectionstringname="ApplicationServices" enablepasswordretrieval="false" enablepasswordreset="true" requiresquestionandanswer="false" requiresuniqueemail="false" maxinvalidpasswordattempts="5" minrequiredpasswordlength="6" minrequirednonalphanumericcharacters="0" passwordattemptwindow="10" applicationname="/">
<profile>
<providers>
<clear>
<add name="AspNetSqlProfileProvider" type="System.Web.Profile.SqlProfileProvider" connectionstringname="ApplicationServices" applicationname="/">
<rolemanager enabled="false">
<providers>
<clear>
<add name="AspNetSqlRoleProvider" type="System.Web.Security.SqlRoleProvider" connectionstringname="ApplicationServices" applicationname="/">
<add name="AspNetWindowsTokenRoleProvider" type="System.Web.Security.WindowsTokenRoleProvider" applicationname="/">
<system.net>
<connectionmanagement>
<add maxconnection="200" address="*">
<system.webserver>
<modules runallmanagedmodulesforallrequests="true">
<system.servicemodel>
<bindings>
<wshttpbinding>
<binding name="WSHttpBinding_IService1" closetimeout="00:01:00">
openTimeout="00:01:00" receiveTimeout="00:10:00" sendTimeout="00:01:00"
bypassProxyOnLocal="false" transactionFlow="false" hostNameComparisonMode="StrongWildcard"
maxBufferPoolSize="524288" maxReceivedMessageSize="65536" messageEncoding="Text"
textEncoding="utf-8" useDefaultWebProxy="true" allowCookies="false">
<readerquotas maxdepth="32" maxstringcontentlength="8192" maxarraylength="16384">
maxBytesPerRead="4096" maxNameTableCharCount="16384" />
<reliablesession ordered="true" inactivitytimeout="00:10:00">
enabled="false" />
<security mode="Message">
<transport clientcredentialtype="Windows" proxycredentialtype="None"> realm="" />
<message clientcredentialtype="Windows" negotiateservicecredential="true">
algorithmSuite="Default" />
<client>
<endpoint address="http://localhost:3331/Service1.svc" binding="wsHttpBinding">
bindingConfiguration="WSHttpBinding_IService1" contract="ServiceReference1.IService1"
name="WSHttpBinding_IService1">
<identity>
<dns value="localhost">
<behaviors>
<servicebehaviors>
<behavior name="">
<servicemetadata httpgetenabled="true">
<servicedebug includeexceptiondetailinfaults="false">
<servicehostingenvironment multiplesitebindingsenabled="true">
And here is the web.config on the WCF service:
<configuration>
<appsettings>
<connectionstrings>
<add name="FirstGuardianConnectionString" connectionstring="Data Source=SYSTEM1;Initial Catalog=FirstGuardian;User ID=sa" providername="System.Data.SqlClient">
<system.web>
<compilation debug="true" targetframework="4.0">
<!--
The <authentication> section enables configuration
of the security authentication mode used by
ASP.NET to identify an incoming user.
-->
<authentication mode="Windows">
<!--
The <customerrors> section enables configuration
of what to do if/when an unhandled error occurs
during the execution of a request. Specifically,
it enables developers to configure html error pages
to be displayed in place of a error stack trace.
<customerrors mode="RemoteOnly" defaultredirect="GenericErrorPage.htm">
<error statuscode="403" redirect="NoAccess.htm">
<error statuscode="404" redirect="FileNotFound.htm">
-->
<pages controlrenderingcompatibilityversion="3.5" clientidmode="AutoID">
<!--
The system.webServer section is required for running ASP.NET AJAX under Internet
Information Services 7.0. It is not necessary for previous version of IIS.
-->
<system.servicemodel>
<services>
<service name="WcfService1.Service1" behaviorconfiguration="WcfService1.Service1Behavior">
<!-- Service Endpoints -->
<endpoint address="" binding="wsHttpBinding" contract="WcfService1.IService1">
<!--
Upon deployment, the following identity element should be removed or replaced to reflect the
identity under which the deployed service runs. If removed, WCF will infer an appropriate identity
automatically.
-->
<identity>
<dns value="localhost">
<endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange">
<behaviors>
<servicebehaviors>
<behavior name="WcfService1.Service1Behavior">
<!-- To avoid disclosing metadata information, set the value below to false and remove the metadata endpoint above before deployment -->
<servicemetadata httpgetenabled="true">
<!-- To receive exception details in faults for debugging purposes, set the value below to true. Set to false before deployment to avoid disclosing exception information -->
<servicedebug includeexceptiondetailinfaults="false">
Thanks&Regards,
swathi