// This event handler is where the actual,
// potentially time-consuming work is done.
private void backgroundWorker1_DoWork(Object sender, DoWorkEventArgs e)
{
// Get the BackgroundWorker that raised this event.
BackgroundWorker worker = (BackgroundWorker)sender;
// Assign the result of the computation
// to the Result property of the DoWorkEventArgs
// object. This is will be available to the
// RunWorkerCompleted eventhandler.
e.set_Result(new Long(ComputeFibonacci(System.Convert.ToInt32
(e.get_Argument()), worker, e)));
//e.Result = ComputeFibonacci((int)e.Argument, worker, e);
} //backgroundWorker1_DoWork