Friday, October 24, 2008

The service cannot be activated due to an exception during compilation

The service 'myservice.svc' cannot be activated due to an exception during compilation. The exception message is: The HttpGetEnabled property of ServiceMetadataBehavior is set to true and the HttpGetUrl property is a relative address, but there is no http base address. Either supply an http base address or set HttpGetUrl to an absolute address..

The story is:
My portal cannot consume the web service, then I saw this event log in window log.

I want to check whether the WS deployment is good, so I changed HttpGetEnabled from false to true so that I can see the metadata in IE.

But setting HttpGetEnabled=true also need set HttpGetUrl as an absolute address. To avoid this, I changed the HttpGetEnabled back to false and then this error is gone.

1 comment:

mary Brown said...

Hi, Great.. Tutorial is just awesome..It is really helpful for a newbie like me.. I am a regular follower of your blog. Really very informative post you shared here. Kindly keep blogging. If anyone wants to become a Front end developer learn from Javascript Training in Chennai . or Javascript Training in Chennai. Nowadays JavaScript has tons of job opportunities on various vertical industry. ES6 Training in Chennai