Home All Groups Group Topic Archive Search About
Author
15 May 2009 5:17 PM
Darin
I have a sqlcommand running and have the timeout set to 3600 seconds. Is
there a way, while it is running before the timeout has occured, to stop
it?

Darin

*** Sent via Developersdex http://www.developersdex.com ***

Author
15 May 2009 5:50 PM
Armin Zingler
Darin wrote:
> I have a sqlcommand running and have the timeout set to 3600 seconds.
> Is there a way, while it is running before the timeout has occured,
> to stop it?

Call the Cancel method. In order to be able to do it, you must execute the
query in another thread, either by explicitly creating the thread or by
starting the query from one of the SqlCommand's Begin* methods.


Armin