private void UnregisterEvents(Application powerPointApp) { powerPointApp.AfterNewPresentation -= _WarnForTweeterOnNewField; _WarnForTweeterOnNewField = null; powerPointApp.PresentationOpen -= _WarnForTweeterField; _WarnForTweeterField = null; }
private void RegisterEvents(Application powerPointApp) { { _WarnForTweeterOnNewField = new EApplication_AfterNewPresentationEventHandler(HandlerForEvent_WarnForTweeterOnNew_AfterNewPresentation); powerPointApp.AfterNewPresentation += _WarnForTweeterOnNewField; } { _WarnForTweeterField = new EApplication_PresentationOpenEventHandler(HandlerForEvent_WarnForTweeter_PresentationOpen); powerPointApp.PresentationOpen += _WarnForTweeterField; } }