コード例 #1
0
        private void OnWorkbookClosed(WorkbookClosedEventArgs e)
        {
            var handler = WorkbookClosed;

            if (handler != null)
                handler(this, e);
        }
コード例 #2
0
        private void OnWorkbookClosed(WorkbookClosedEventArgs e)
        {
            var handler = WorkbookClosed;

            if (handler != null)
            {
                handler(this, e);
            }
        }
コード例 #3
0
        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;
            }
        }
コード例 #4
0
        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;
            }
        }