المساعد الشخصي الرقمي

مشاهدة النسخة كاملة : Thread issue



C# Programming
01-28-2010, 05:41 AM
I realise that I could wade through SBs threading 1-5 but I'm as lazy as the next person.

If I fire of a long running thread from the winform, that calls multiple methods in the business object layer which call stored procs and the user closes the form before the thread has completed, what happens to the thread.

I assume it completes the current stored proc and then terminates.

I use the following to call start the thread

var t = new Thread(() => DoTB(iPeriodID));
t.Start();


Never underestimate the power of human stupidity
RAH