Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 3874084
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 19, 20262026-05-19T22:06:41+00:00 2026-05-19T22:06:41+00:00

That Metadata error is what I get when I browse to the service in

  • 0

That Metadata error is what I get when I browse to the service in a browser. I am not consuming it with a client

and Yes.. I added <serviceMetadata httpGetEnabled="True"/>, and I have a mex endpoint defined

but it still won’t work..

So I created a barebones service to host on IIS7. Fresh install of Windows 7 and VS2010.

I had followed the instructions of this page to the letter:

http://msdn.microsoft.com/en-us/library/ms733766.aspx

I’m convinced that this has to be some sort of configuration issue with IIS7 but and not sure. Here’s my service setup:

EDIT:

I tried accessing the service with svcutil and got the following error:

The remote server returned an error: (415) Cannot process the message because the content type 'application/soap+xml; charset=utf-8' was not the expected type 'text/xml; charset=utf-8'..

it also says: The HTML document does not contain Web service discovery information.

not sure how to resolve it, however..

.svc file:

<%@ServiceHost language="C#" Debug="true" Service="DestructionServices.TacticalNukeSVC“%>

.cs file (located in the C:\Development\HostedDestructionServices\App_Code folder):

using System;
using System.ServiceModel;

namespace DestructionServices
{
    [ServiceContract]
    public interface INukeInterface
    {
        [OperationContract]
        string FireMissile();

        [OperationContract]
        string DirectFire(double x, double y, double z);

        [OperationContract]
        void EnterCoordinates(double x, double y, double z);
    }

    public class TacticalNukeSVC : INukeInterface
    {
        public string FireMissile()
        {
            return "Boom";
        }

        public void EnterCoordinates(double x, double y, double z)
        {
            //bah, who cares about coordinates..
        }

        public string DirectFire(double x, double y, double z)
        {
            return "Fired at: " + x + ", " + y + ", " + z;
        }
    }
}

Web.Config:

<?xml version="1.0" encoding="utf-8"?>
<configuration>
  <system.serviceModel>
    <services>
      <service name="DestructionServices.Destro" behaviorConfiguration="MetadataBehavior">
        <endpoint address="" binding="wsHttpBinding" contract="DestructionServices.INukeInterface" />
        <endpoint address="mex" binding="mexHttpBinding" contract="IMetadataExchange" />
      </service>
    </services>
    <behaviors>
      <serviceBehaviors>
        <behavior name="MetadataBehavior">
          <serviceDebug includeExceptionDetailInFaults="True" httpHelpPageEnabled="True" />
          <serviceMetadata httpGetEnabled="True"/>
        </behavior>
      </serviceBehaviors>
    </behaviors>
  </system.serviceModel>
</configuration>

IIS

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-19T22:06:42+00:00Added an answer on May 19, 2026 at 10:06 pm

    Your code and config seems fine – except for one little point:

    In your <service> tag, you have defined a name that doesn’t seem to correspond to the class that actually implements your service:

    <service name="DestructionServices.Destro"  ......>
                   ************************** 
    

    but your class is:

    namespace DestructionServices
    {
        .....
        public class TacticalNukeSVC : INukeInterface
        {
    

    Those names need to match! The name= attribute on the <service> tag in config must be exactly what your service class is called – fully qualified, including namespace – so in your case here, it should be:

    <service name="DestructionServices.TacticalNukeSVC" ......>
    
    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

When I browse to the .svc I continually get the error: Metadata publishing for
I get this error when I attempt to run the wcftestclient application: The client
I'm trying to create a client for a WCF service that I have hosted
EDIT: After I modified the web.config and I don't get error that's good.... then
I know that join is not supported on client side with WCF DS thats
I have several pieces of metadata that I need to associate with a push
I want to have a program that reads metadata from an MP3 file. My
I know that it is possible to add swf metadata to the compile command
I know that .NET assembly is self-descriptive because of the metadata. Now suppose I
I am coding a fairly complex system that uses a lot of metadata to

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.