public override void SetTask(object task) { baseTask = task as ITaskEx; baseTask.SetTaskControl(new ProxyTaskControl(this)); ScheduleMode = true; baseTask.Run(); }
public override void Execute(object scheduler) { Scheduler = scheduler as SchedulerEngineEx; ScheduleMode = false; Status = Status.Running; try { baseTask.Run(); } catch (Exception e) { Console.Out.WriteLine(e.Message); Console.Out.WriteLine(e.StackTrace); Console.Out.Flush(); CancelTask(CurrentActivity); } }