title: Add Service Reference not working for WCF service without SVC file
body: <p>I have an existing WCF service which does not have *.SVC file. The project itself is website and WCF code is written in it. It is using this line for registering service:</p>
  
  <pre><code>RouteTable.Routes.Add(new ServiceRoute("", new WebServiceHostFactory(), typeof(Service1)));
  </code></pre>
  
  <p>I run the project from Visual Studio and check from IE that the service is hosted and working by testing following method: </p>
  
  <pre><code>http://localhost:51838/GetBenchMark/20
  </code></pre>
  
  <p>I have to create a console app which makes use of this WCF service. When I try to use "Add Service Reference" from Visual studio and give the path <code>http://localhost:51838/</code>, it is not able to find it and gives error:</p>
  
  <pre><code>    The HTML document does not contain Web service discovery information.
  Metadata contains a reference that cannot be resolved: 'http://localhost:51838/'.
  There was no endpoint listening at http://localhost:51838/ that could accept the message. This is often caused by an incorrect address or SOAP action. See InnerException, if present, for more details.
  The remote server returned an error: (404) Not Found.
  If the service is defined in the current solution, try building the solution and adding the service reference again.
  </code></pre>
  
  <p>This is web.config if it helps:</p>
  
  <pre><code> &lt;system.web&gt;
      &lt;compilation debug="true" targetFramework="4.0"&gt;
        &lt;assemblies&gt;
          &lt;add assembly="System.Data.Entity, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089" /&gt;
        &lt;/assemblies&gt;
      &lt;/compilation&gt;
    &lt;/system.web&gt;
    &lt;system.web.extensions&gt;
      &lt;scripting&gt;
        &lt;webServices&gt;
          &lt;jsonSerialization maxJsonLength="2147483647" /&gt;
        &lt;/webServices&gt;
      &lt;/scripting&gt;
    &lt;/system.web.extensions&gt;
    &lt;system.webServer&gt;
      &lt;validation validateIntegratedModeConfiguration="false" /&gt;
      &lt;modules runAllManagedModulesForAllRequests="true"&gt;
        &lt;add name="UrlRoutingModule" type="System.Web.Routing.UrlRoutingModule, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" /&gt;
      &lt;/modules&gt;
    &lt;/system.webServer&gt;
    &lt;system.serviceModel&gt;
      &lt;client /&gt;
      &lt;serviceHostingEnvironment aspNetCompatibilityEnabled="true" /&gt;
      &lt;standardEndpoints&gt;
        &lt;webHttpEndpoint&gt;
          &lt;!-- 
              Configure the WCF REST service base address via the global.asax.cs file and the default endpoint
              via the attributes on the &lt;standardEndpoint&gt; element below
          --&gt;
          &lt;standardEndpoint name="" helpEnabled="true" automaticFormatSelectionEnabled="true" maxReceivedMessageSize="2147483647" maxBufferSize="2147483647" maxBufferPoolSize="2147483647" /&gt;
        &lt;/webHttpEndpoint&gt;
      &lt;/standardEndpoints&gt;
      &lt;bindings&gt;
        &lt;webHttpBinding&gt;
          &lt;binding closeTimeout="00:20:00" openTimeout="00:20:00" receiveTimeout="00:20:00" sendTimeout="00:20:00" allowCookies="false" bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard" maxBufferSize="2147483647" maxBufferPoolSize="524288" maxReceivedMessageSize="2147483647" transferMode="Buffered" useDefaultWebProxy="true"&gt;
            &lt;readerQuotas maxDepth="2147483647" maxStringContentLength="2147483647" maxArrayLength="2147483647" maxBytesPerRead="2147483647" maxNameTableCharCount="2147483647" /&gt;
          &lt;/binding&gt;
        &lt;/webHttpBinding&gt;
      &lt;/bindings&gt;
    &lt;/system.serviceModel&gt;
  </code></pre>
  
  <p>Please let me know what should I do to generate proxy classes and start using this service from console app.</p>