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

  • SEARCH
  • Home
  • 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 155511
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 11, 20262026-05-11T10:10:07+00:00 2026-05-11T10:10:07+00:00

I am still learning the whole WCF thing, so please bear with me here.

  • 0

I am still learning the whole WCF thing, so please bear with me here.

What I have is two self hosted services created using C# and VS 2008:
Service # 1 Adds two numbers and returns the result.
Service # 2 Returns the square of a number.

I want the client to be able to send in two numbers to Service 1, get the sum and then send the sum in to Service 2 and get the square.

I have two generated proxies for both the services, and I am able to use Intellisense on them, so that part supposedly works.

Now how do i configure my app.config file such that I can communicate with both the services? Right now, i get an exception every time I try to do that.

[The client works fine if I only have one of the configurations in the app file at a time, and try to call only that server.]

I suppose this is a very noobish question, and the answer probably is ‘structure the config file in _____ manner’, but Google simply does not seem to have an example/guide.

Anyone know how to do this?

Note: Consume multiple WCF services from one client client Though sounds like a duplicate is NOT what I am looking for.

Edit: Thanks to marc_s, I got it working

With both the services running in different apps, I did not need to split the server config file, but here is what I did with the client config files: First auto-generated the config files using SvrUtil.exe and then merged them in this way:

<bindings>   <wsHttpBinding>      <binding>     ...     </binding>      <binding>     ...     </binding>    </wsHttpBinding> </bindings> 

…

  <endpoint> 

…

  • 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. 2026-05-11T10:10:08+00:00Added an answer on May 11, 2026 at 10:10 am

    If you want to run the two services on separate endpoints / ports, do something like this:

    Server-side:

    <service name='Service1'>     <endpoint address='http://localhost:8001/service1.asmx'             binding='basicHttpBinding'             contract='IService1' /> </service> <service name='Service2'>     <endpoint address='http://localhost:8002/service2.asmx'              binding='basicHttpBinding'             contract='IService2' /> </service> 

    Client-side:

    <client>     <endpoint address='http://localhost:8001/service1.asmx'             binding='basicHttpBinding'             contract='IService1'             name='Service1' />     <endpoint address='http://localhost:8002/service2.asmx'              binding='basicHttpBinding'             contract='IService2'             name='Service2' /> </client> 

    That should give you two separate, individual endpoints on the server and a client that will talk to both.

    Marc

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Ask A Question

Stats

  • Questions 124k
  • Answers 124k
  • Best Answers 0
  • User 1
  • Popular
  • Answers
  • Editorial Team

    How to approach applying for a job at a company ...

    • 7 Answers
  • Editorial Team

    How to handle personal stress caused by utterly incompetent and ...

    • 5 Answers
  • Editorial Team

    What is a programmer’s life like?

    • 5 Answers
  • Editorial Team
    Editorial Team added an answer Perhaps FSDB (file system data base) will suit your needs.… May 12, 2026 at 1:17 am
  • Editorial Team
    Editorial Team added an answer Open Windows Explorer. Right-click anywhere in the window. Click TortoiseSVN… May 12, 2026 at 1:17 am
  • Editorial Team
    Editorial Team added an answer Yes - Go "Debug / New breakpoint / Break at… May 12, 2026 at 1:17 am

Related Questions

Does anybody know of or have a detailed list of how the BCL in
I am still learning C++, and I have never really created my own namespaces
I've been using javascript for a while, but have never learned the language past
I am working on a form in C# that is used for displaying information,

Trending Tags

analytics british company computer developers django employee employer english facebook french google interview javascript language life php programmer programs salary

Top Members

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.