By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,825 Members | 1,281 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,825 IT Pros & Developers. It's quick & easy.

Message="There was an error during async processing."

P: n/a
Hi all,

I have a windows app that makes some asyc calls to my webservice
(WSE
3.0 with MTOM).
>From time to time when the user cancels the async call, the following
exception gets thrown in the client win app. I know this exception
is caused on
the async completed call back, but I have not been able to
catch it and dispose of it.
How can gracefully handle this exception?

Any help greatly appreciated.
Rich

my completed event handler:

private void proxy_DoSomethingCompleted(object sender,
DoSomethingCompletedEventArgs Completed)
{
if(!Completed.Cancelled)
{
if (Completed.Error == null)
{
// do something with the Completed.Results
}

}
}

The Excpeption being thrown:

System.InvalidOperationException was unhandled
Message="There was an error during async processing."
Source="System.Web.Services"
StackTrace:
at
System.Web.Services.Protocols.WebClientProtocol.Pr ocessAsyncException(WebCl*
ientAsyncResult
client, Exception e)
at
System.Web.Services.Protocols.WebClientProtocol.Re adResponseAsyncCallback(I*
AsyncResult
asyncResult)
at System.Net.LazyAsyncResult.Complete(IntPtr userToken)
at System.Net.ContextAwareResult.CompleteCallback(Obj ect
state)
at System.Threading.ExecutionContext.runTryCode(Objec t
userData)
at
System.Runtime.CompilerServices.RuntimeHelpers.Exe cuteCodeWithGuaranteedCle*
anup(TryCode
code, CleanupCode backoutCode, Object userData)
at
System.Threading.ExecutionContext.RunInternal(Exec utionContext
executionContext, ContextCallback callback, Object state)
at System.Threading.ExecutionContext.Run(ExecutionCon text
executionContext, ContextCallback callback, Object state)
at System.Net.ContextAwareResult.Complete(IntPtr userToken)
at System.Net.LazyAsyncResult.ProtectedInvokeCallback (Object
result, IntPtr userToken)
at
System.Net.Sockets.BaseOverlappedAsyncResult.Compl etionPortCallback(UInt32
errorCode, UInt32 numBytes, NativeOverlapped* nativeOverlapped)
at
System.Threading._IOCompletionCallback.PerformIOCo mpletionCallback(UInt32
errorCode, UInt32 numBytes, NativeOverlapped* pOVERLAP)

Apr 19 '07 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.