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

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T01:56:04+00:00 2026-05-24T01:56:04+00:00

I have this client application that sends thousands of items for deletion to my

  • 0

I have this client application that sends thousands of items for deletion to my wcf service. Since the data is sent in bulk, even if I cancel the operation (with progress bar), all items are deleted. The behavior I want is to be able to cancel the delete operation in the service and retrieve items that are not deleted. Thank you.

  • 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-24T01:56:04+00:00Added an answer on May 24, 2026 at 1:56 am

    What InstanceContextMode are you using?

    What you want to do will work with InstanceContextMode Singleton or Session, but not PerCall.

    I suppose that your method that initiates the delete in bulk operation is OneWay.

    Create a bool field (initially false) in your service. Your loop that deletes records one by one checks that flag and stops if the flag is true.

    Create another method in your service that sets that field to true. Call the new method from your website when you press the “Cancel Delete” button. The looop for deleting records will break.

    Returning the records that were not deleted will be a bit tricky. Your list of records to delete will need to be a memebr of the service class also, so that the method that stops the delete has access to the list also. The method that deletes from the db shoulkd also remove the records from the list one by one so you can keep track of remaining items.

    You could return immediately in the second method the list, but thia does not guarantee accurate results. What I would do is do a wait of 200 ms before returning. That way you know that the item removed from the list is really deleted in the db.

    Hope this is clear…

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

Sidebar

Related Questions

Lets suppose I have an .NET client application that connects to a WCF service,
Hi I have an application that operations like this.. Client <----> Server <----> Monitor
We have a C# .Net client application that sends some commands via REST over
We have a WCF (Windows Communication Foundation) client and service application. We're using Windows
I have a C application that sends data to a UDP server every few
I have a client server application that sends XML over TCP/IP from client to
I currently have an application that sends XML over TCP sockets from windows client
i have this client/server application, and the client application sometimes completely freezes when i
We have a desktop client application developed in Swing. This application interacts with backend
I am wondering how this is done.Suppose i have a client application and it

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.