D
David Shreffler
I have a web form that asynchronously calls a web service on the local
machine. The problem is that when the callback delegate fires, and calls
the End... web method, no results return and no further code within the
function executes. I tried wrapping the End... call in a try/catch block
and no exception is being thrown. The callback delegate is definitely
firing since I set a breakpoint on it and it stopped appropriately.
I have tested the web service by calling it synchronously, and it works just
fine. However, that was with dummy return values. The real web service
takes 30-45 min (crunching millions of records) so it needs to be called
asynchronously.
I am assuming it's a problem with threading. I've read other examples where
this kind of problem occurred and the solution was to have the callback
delegate invoke another delegate on the original thread that called the web
service (rather than the worker thread the web service created). However,
since I'm dealing with web forms and web controls, there is no invoke method
to call.
VS.NET solution background:
I have one solution, containing a web form application project and another
project for the web service. The solution has both of the projects start,
and has the web form (consumer application) dependent on the web service
project to ensure the web service is compiled first. The web service
project
Thoughts??
Thanks!!!!
David.
PS- This problem is similar to this developer's problem:
http://www.dotnet247.com/247reference/msgs/7/38335.aspx
machine. The problem is that when the callback delegate fires, and calls
the End... web method, no results return and no further code within the
function executes. I tried wrapping the End... call in a try/catch block
and no exception is being thrown. The callback delegate is definitely
firing since I set a breakpoint on it and it stopped appropriately.
I have tested the web service by calling it synchronously, and it works just
fine. However, that was with dummy return values. The real web service
takes 30-45 min (crunching millions of records) so it needs to be called
asynchronously.
I am assuming it's a problem with threading. I've read other examples where
this kind of problem occurred and the solution was to have the callback
delegate invoke another delegate on the original thread that called the web
service (rather than the worker thread the web service created). However,
since I'm dealing with web forms and web controls, there is no invoke method
to call.
VS.NET solution background:
I have one solution, containing a web form application project and another
project for the web service. The solution has both of the projects start,
and has the web form (consumer application) dependent on the web service
project to ensure the web service is compiled first. The web service
project
Thoughts??
Thanks!!!!
David.
PS- This problem is similar to this developer's problem:
http://www.dotnet247.com/247reference/msgs/7/38335.aspx