C# 此服务的元数据发布当前已禁用

C# 此服务的元数据发布当前已禁用,c#,asp.net,C#,Asp.net,我得到了这个错误 此服务的元数据发布当前已禁用 我的web.config文件是 <?xml version="1.0"?> <configuration> <system.web> <compilation debug="true" targetFramework="4.0"/> </system.web> <system.serviceModel> <se

我得到了这个错误

此服务的元数据发布当前已禁用

我的
web.config
文件是

 <?xml version="1.0"?>
 <configuration>
    <system.web>
        <compilation debug="true" targetFramework="4.0"/>
    </system.web>

    <system.serviceModel>
        <services>
            <service name="WCFService1.Service">
                <endpoint address=""  binding="wsHttpBinding" contract="WCFService1.IService"  /> 
                <endpoint address="mex" binding="mexHttpBinding"   contract="IMetadataExchange" />
            </service>
        </services>
        <behaviors>
            <serviceBehaviors>
                <behavior name="ServiceBehavior">
                    <serviceMetadata httpGetEnabled="true"/>
                    <serviceDebug includeExceptionDetailInFaults="false" httpHelpPageEnabled="True"/>
                </behavior>
            </serviceBehaviors>
        </behaviors>

        <serviceHostingEnvironment multipleSiteBindingsEnabled="true" />
    </system.serviceModel>

    <system.webServer>
        <modules runAllManagedModulesForAllRequests="true"/>
        <directoryBrowse enabled="true"/>
    </system.webServer>
</configuration>

您在哪里/何时收到错误?在编译过程中?发射时?在访问特定页面时?在本地服务器上,当在服务器上发布时,一切都正常。我收到此错误
public class Service : IService1    
public interface IService1
{
    [OperationContract]