cancellationPending없이 backgroundWorker 스레드를 중지 할 수있는 방법이 있습니까? 나는이 같은 코드를 가지고 :C# 취소없이 backgroundWorker를 실행 중지하는 방법
DoWorkFunction
{
if(worker.cancellationPending == true) return; //this works great but
VeryLongTimeComputingFunc();//this function take a lot of time and if it starts i can't stop it with cancellationPending
...Do something
}
)은 (는 VeryLongTimeComputingFunc를 시작하는 경우에도 근로자를 막을 수있는 방법이 있습니까?