// Display notofication after successfull adding to calendar public override void Completed(EKEventEditViewController controller, EKEventEditViewAction action) { eventController.DismissViewController(true, null); if (action == EKEventEditViewAction.Saved) { AppNotifications.Display(new DisplayedPromptsModel() { Category = "", Task = "Task has been successfully scheduled" }); } }
public override void Completed(EKEventEditViewController controller, EKEventEditViewAction action) { switch (action) { case EKEventEditViewAction.Canceled: if (_viewModel.CancelEventCommand.CanExecute(null)) { _viewModel.CancelEventCommand.Execute(null); } break; case EKEventEditViewAction.Saved: if (_viewModel.SaveEventCommand.CanExecute(null)) { _viewModel.SaveEventCommand.Execute(null); } break; } }
// completed is called when a user eith public override void Completed(EKEventEditViewController controller, EKEventEditViewAction action) { _eventController.DismissViewController(true, null); switch (action) { case EKEventEditViewAction.Canceled: _success = false; break; case EKEventEditViewAction.Saved: _success = true; break; case EKEventEditViewAction.Deleted: _success = false; break; default: throw new ArgumentOutOfRangeException(nameof(action), action, null); } }
// completed is called when a user eith public override void Completed(MonoTouch.EventKitUI.EKEventEditViewController controller, EKEventEditViewAction action) { eventController.DismissViewController (true, null); // action tells you what the user did in the dialog, so you can optionally // do things based on what their action was. additionally, you can get the // Event from the controller.Event property, so for instance, you could // modify the event and then resave if you'd like. switch ( action ) { case EKEventEditViewAction.Canceled: break; case EKEventEditViewAction.Deleted: break; case EKEventEditViewAction.Saved: // if you wanted to modify the event you could do so here, and then // save: //App.Current.EventStore.SaveEvent ( controller.Event, ) break; } }
// completed is called when a user eith public override void Completed(MonoTouch.EventKitUI.EKEventEditViewController controller, EKEventEditViewAction action) { eventController.DismissViewController(true, null); // action tells you what the user did in the dialog, so you can optionally // do things based on what their action was. additionally, you can get the // Event from the controller.Event property, so for instance, you could // modify the event and then resave if you'd like. switch (action) { case EKEventEditViewAction.Canceled: break; case EKEventEditViewAction.Deleted: break; case EKEventEditViewAction.Saved: // if you wanted to modify the event you could do so here, and then // save: //App.Current.EventStore.SaveEvent ( controller.Event, ) break; } }
/// <Docs>To be added.</Docs> /// <summary> /// Completion Handler /// </summary> /// <param name="controller">Controller.</param> /// <param name="action">Action.</param> public override void Completed(MonoTouch.EventKitUI.EKEventEditViewController controller, EKEventEditViewAction action) { if (mDatasource.PopController != null) { mDatasource.PopController.Dismiss(true); mDatasource.PopController = null; mDatasource.ClearViews(); } else { eventController.DismissViewController(true, null); } switch (action) { case EKEventEditViewAction.Canceled: break; case EKEventEditViewAction.Deleted: { //reload the calendar view mCalendarView.ReloadData(); } break; case EKEventEditViewAction.Saved: { NSError e; eventController.EventStore.SaveEvent(controller.Event, EKSpan.ThisEvent, out e); //reload the calendar view mCalendarView.ReloadData(); } break; } }
public override void Completed(EKEventEditViewController controller, EKEventEditViewAction action) { switch (action) { case EKEventEditViewAction.Canceled: { BackToParentController(); break; } case EKEventEditViewAction.Saved: { BackToParentController(); NSError e; EventSingleton.Current.EventStore.SaveEvent(_parentController.Event, EKSpan.ThisEvent, out e); break; } } }
// completed is called when a user eith public override void Completed(EventKitUI.EKEventEditViewController controller, EKEventEditViewAction action) { eventController.DismissViewController(true, null); switch (action) { case EKEventEditViewAction.Canceled: break; case EKEventEditViewAction.Deleted: break; case EKEventEditViewAction.Saved: NSError error; eventStore.SaveEvent(controller.Event, EKSpan.ThisEvent, out error); break; } }