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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 20, 20262026-05-20T04:43:12+00:00 2026-05-20T04:43:12+00:00

How can I set up an asynchronous web service in asp.net? I want to

  • 0

How can I set up an asynchronous web service in asp.net?

I want to call a webservice to post some data to a database, but I don’t care if the response failed or succeeded.

I can use .net 2.0 or 3.5 only and it can be in vb or c#.

  • 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-20T04:43:13+00:00Added an answer on May 20, 2026 at 4:43 am

    When you create the service reference in visual studio click the “Advanced…” button and check off “Generate asynchronous operations”. Then you’ll have the option to make asynchronous calls against the web service.

    Here’s a sample of both a synchronous and the same asynchronous call to a public web service.

    // http://wsf.cdyne.com/WeatherWS/Weather.asmx?wsdl
    using(var wf = new WeatherForecasts.WeatherSoapClient())
    {
        // example synchronous call
        wf.GetCityForecastByZIP("20850");
    
        // example asynchronous call
        wf.BeginGetCityForecastByZIP("20850", result => wf.EndGetCityForecastByZIP(result), null);
    }
    

    It might be tempting to just call BeginXxx and not do anything with the result since you don’t care about it. You’ll actually leak resources though. It’s important that every BeginXxx call is matched with a corresponding EndXxx call.

    Even though you have a callback that calls EndXxx, this is triggered on a thread pool thread and the original thread that called BeginXxx is free to finish as soon as the BeginXxx call is done (it doesn’t wait for the response).

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

Sidebar

Related Questions

You can set the Vim color scheme by issuing :colorscheme SCHEME_NAME but, oddly enough,
I have an ASP.NET page that needs to make calls to multiple web services
So i'm dealing with an ASP.NET 4.0 Web Forms Application in which the DAL
I'm using ASIHTTPRequest API to get some JSON data from a web side. I'm
I'm trying to download a file I recieve on the web into my ASP.NET
I need to set an asynchronous call for research on uisearchbar on Tableview on
I can set the width and height of my canvas by setting the width
I can set the relationship between View Model and view through following DataContext syntax:
I can set the event on the calendar on my device by using this
How can I can set a global variable for the username of the logged-in

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.