Newbie question on performing/handling Asynchronous operations..

  • Thread starter Thread starter Dr Deadpan
  • Start date Start date
D

Dr Deadpan

Hi,

I have a dotnet form that basically writes to the webserver when a
button is clicked. Now based on the amount of data, the writing could
take about 5-10 minutes.

I was wondering if there was a way for me to post a message back to
the user
as soon as the button is clicked and then have the webserver continue
to perform the operation. This way the user gets an immediate repsonse
saying that teh operationis being performed and does'nt have to wait
that long. This will also take care of potential timeout situations.

Can someone give me some examples/ code snippets/links that will
help me out
if it indeed is possible. Please rememberthat I am new at this, so the
more
info the better and the more code with explanation the better.


Regards,

DrD
 
Hi DrD,

You can call the web service asynchronously. When you create the Web
Reference, all web methods in th proxy are created with a Begin<methodName>
and End<methodName> signature. Here's an example of how to implement
asynchronous delegates:

http://msdn.microsoft.com/library/d...conasynchronousdelegatesprogrammingsample.asp

Look at the last example with the FactorizeResults callback.

Also, here's an MSDN TV episode where Mark Boulter explains in less than 5
minutes how to do this from a Windows Forms app:

http://msdn.microsoft.com/msdntv/episode.aspx?xml=episodes/en/20030409WinFormsMB/manifest.xml

Joe
 
Joe Mayo said:
Hi DrD,

You can call the web service asynchronously. When you create the Web
Reference, all web methods in th proxy are created with a Begin<methodName>
and End<methodName> signature. Here's an example of how to implement
asynchronous delegates:

http://msdn.microsoft.com/library/d...conasynchronousdelegatesprogrammingsample.asp

Look at the last example with the FactorizeResults callback.

Also, here's an MSDN TV episode where Mark Boulter explains in less than 5
minutes how to do this from a Windows Forms app:

http://msdn.microsoft.com/msdntv/episode.aspx?xml=episodes/en/20030409WinFormsMB/manifest.xml

Thanks for the links, thought a little too advanced for me. I will try
and learn. ANy other links, suggestions ( easier ones maybe)

DrD
 
Back
Top