MindFusion.Wpf Pack Programmer's Guide
Workbook.CancelCompositeOperation Method
See Also
 





Stops recording the most recently started composite operation and discards the records created so far.

Namespace: MindFusion.Spreadsheet.Wpf
Assembly: MindFusion.Spreadsheet.Wpf

 Syntax

C#  Copy Code

public void CancelCompositeOperation ()

Visual Basic  Copy Code

Public Sub CancelCompositeOperation ()

 Remarks

The usual scenario for cancelling a composite command is when an exception happens while the command is active. The code below illustrates this scenario.

C#  Copy Code

var command = workbook.StartCompositeOperation();
try
{
    // Operations go here
    workbook.CommitCompositeOperation();
}
catch
{
    workbook.CancelCompositeOperation();
}

Visual Basic  Copy Code

Dim command = workbook.StartCompositeOperation()
Try

    ' Changes on the worksheet go here
    workbook.CommitCompositeOperation()

Catch

    workbook.CancelCompositeOperation()

End Try

Alternatively, the command can be cancelled by calling its Cancel method.

 See Also

Workbook Members
Workbook Class
MindFusion.Spreadsheet.Wpf Namespace