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 4048304
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T13:48:01+00:00 2026-05-20T13:48:01+00:00

I am asking for some advice (so sorry if this has been asked before):

  • 0

I am asking for some advice (so sorry if this has been asked before):

When I call WCF services I use the following pattern. I developed this pattern way back with early WCF releases (in VS2008) and am curious now if this Close()/Abort() pattern is still necessary in the current version of WCF (in VS2010). It certainly does work.

I have looked into this and I see many examples calling WCF clients without this pattern, but I also know that many samples on the Internet are inferior. But is it overkill? What’s the ideal pattern?

If you do have the answer, it is very important to me that you provide some type of reference so I can research into your suggestion.

  var _Client = new MyServiceReference.MyServiceClient();
  try
  {
      var _Item = _Client.GetItem(123);
      _Client.Close();
      return _Item;
  }
  catch
  {
      _Client.Abort();
      throw;
  }
  • 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-20T13:48:01+00:00Added an answer on May 20, 2026 at 1:48 pm

    Yes, this is still pretty much the recommended best practice.

    See: MSDN Avoiding Problems with the Using Statement

    Not much has changed in the way the WCF clients call a service, and how to deal with exceptions and errors.

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

Sidebar

Related Questions

I've been into this problem for a while already, and have asked some questions
I'm really asking this by proxy, another team at work has had a change
Firstly, I've asked this question elsewhere , but meta.stackoverflow.com seems to think that asking
After asking some general advice on shortest path algorithms ( 2D waypoint pathfinding: combinations
Most of my programming has been in web-based applications, although I have done some
After asking this question I was advised not to check in binaries into subversion.
I'm asking this question purely from a usability standpoint ! Should a website expand/stretch
I'm asking more about what this means to my code. I understand the concepts
I'm somewhat new to Python, Django, and I'd like some advice on how to
I asked a question earlier which elicited some great responses. Here's the earlier question

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.