Exemplo n.º 1
0
        public BGWorker(StartFunc startFunc, CompleteFunc completeFunc)
        {
            _startFunc = startFunc;
            _completeFunc = completeFunc;

            bw = new BackgroundWorker();
            bw.DoWork += DoWork;
            bw.RunWorkerCompleted += Complete;
            bw.RunWorkerAsync();
        }
Exemplo n.º 2
0
 public BGWorker(StartFunc startFunc, CompleteFunc completeFunc)
 {
     _startFunc    = startFunc;
     _completeFunc = completeFunc;
     bw            = new BackgroundWorker();
     bw.WorkerSupportsCancellation = true;
     bw.DoWork             += DoWork;
     bw.RunWorkerCompleted += Complete;
     bw.RunWorkerAsync();
 }
Exemplo n.º 3
0
        public BGWorker(StartFunc startFunc, CompleteFunc completeFunc)
        {

            _startFunc = startFunc;
            _completeFunc = completeFunc;
            bw = new BackgroundWorker();
            bw.WorkerSupportsCancellation = true;
            bw.DoWork += DoWork;
            bw.RunWorkerCompleted += Complete;
            bw.RunWorkerAsync();
        }