Пример #1
0
        public void taskScheduler_Schedule(object sender, TaskScheduleEventArgs e)
        {
            taskItem = e.Task;
            //the calling thread cannot access this object because a different thread owns it.
            //btnSnooze.IsEnabled = true;

            //textBoxTaskDetails.Text = taskItem.Details;
            //this.WindowState = WindowState.Normal;

            // Place delegate on the Dispatcher.
            this.Dispatcher.Invoke(DispatcherPriority.Normal, new UpdateUIControls(UpdateUI));
        }
Пример #2
0
 public void taskScheduler_Schedule(object sender, TaskScheduleEventArgs e)
 {
     Console.WriteLine("command interpreter Thread id: {0}", Thread.CurrentThread.ManagedThreadId);
     Console.WriteLine("Command Interpreter: Task ID: {0} TaskTime: {1}", e.Task.ID, e.Task.TimeReminder);
 }