private void reportCompletion(IAsyncResult pAsyncResult)
        {
            AsyncResult        _asyncResult = (AsyncResult)pAsyncResult;
            DoWorkEventHandler _del         = (DoWorkEventHandler)_asyncResult.AsyncDelegate;

            WorkerEventArgs _doWorkArgs = (WorkerEventArgs)pAsyncResult.AsyncState;
            object          _result     = null;
            Exception       _error      = null;

            try {
                _del.EndInvoke(pAsyncResult);
                _result = _doWorkArgs.Result;
            }
            catch (Exception _ex) {
                _error = _ex;
            }

            WorkCompletedEventArgs _completedArgs = new WorkCompletedEventArgs(_result, _error, _doWorkArgs.Cancel);

            onWorkerCompleted(_completedArgs);
        }
        public void ReportWorkCompleted(object pResult, Exception pError, bool pCancel)
        {
            WorkCompletedEventArgs _dataReceivedArgs = new WorkCompletedEventArgs(pResult, pError, pCancel);

            onWorkerCompleted(_dataReceivedArgs);
        }
 protected virtual void onWorkerCompleted(WorkCompletedEventArgs pCompletedArgs)
 {
     ProcessDelegate(WorkCompleted, this, pCompletedArgs);
 }