private void OnWorkbookClosed(WorkbookClosedEventArgs e) { var handler = WorkbookClosed; if (handler != null) handler(this, e); }
private void OnWorkbookClosed(WorkbookClosedEventArgs e) { var handler = WorkbookClosed; if (handler != null) { handler(this, e); } }
private void ApplicationWorkbookActivate(Workbook wb) { // A workbook was closed if a request is pending and the workbook count decreased var wasWorkbookClosed = PendingRequest != null && Application.Workbooks.Count < PendingRequest.WorkbookCount; if (wasWorkbookClosed) { var args = new WorkbookClosedEventArgs(PendingRequest.Workbook); PendingRequest = null; OnWorkbookClosed(args); } else { PendingRequest = null; } }
private void ApplicationWorkbookActivate(Workbook wb) { // A workbook was closed if a request is pending and the workbook count decreased var wasWorkbookClosed = PendingRequest != null && Application.Workbooks.Count < PendingRequest.WorkbookCount; if (wasWorkbookClosed) { var args = new WorkbookClosedEventArgs(PendingRequest.Workbook); PendingRequest = null; OnWorkbookClosed(args); } else { PendingRequest = null; } }