troubleshooting Question

WCF Service. svcutil.exe will not generat app.config file...

Avatar of keyuk
keyukFlag for United Kingdom of Great Britain and Northern Ireland asked on
.NET ProgrammingWCF
2 Comments2 Solutions3186 ViewsLast Modified:
Hi Experts,

We have recently created a WCF service and have it hosted and running very happily.

I'm now writing a client website using an Asp.Net web project and have added the service as a reference. This has generated all the necessary bits I need to access the service and classes etc.

I've added using System.ServiceModel to the code behind and am trying to create a proxy client to use with the reference. The line myref.MyServiceClient proxy = new myref.MyServiceClient(); throws a "Could not find default endpoint element that references contract.... etc.

I did try creating the proxy client class by running svcUtil.exe and adding the generated files to my app, but the utility didn't create an app.config - which it's supposed to do - right?

I'm using VS2010 Beta 2 and .Net 4.0, so not sure if I'm running into bugs, or I'm just not setting things up correctly. I'm also not sure if I'm even using the technology properly as WCF is very new to me. Can anyone shed any light on how to create a client web app for using WCF services that should work.

Many thanks!
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 2 Answers and 2 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 2 Answers and 2 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros