I remember with ASMX there was an easy solution:
MyAsmxServiceClient serviceClient =
new MyAsmxServiceClient("http://myServiceLocation/myService.asmx");
How can achieve the same with WCF?
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
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.
That’s usually done in the app.config/web.config:
or you could also do it programatically if you prefer.
Normally when you generate the client side proxy using the svcutil.exe it will also create a sample
output.configfile containing all you need to setup the configuration.UPDATE:
You could also provide names to your endpoints:
and then: