Spread WPF Documentation
InvalidOperation Event (GcSpreadSheet)
Example 


GrapeCity.Windows.SpreadSheet.UI Namespace > GcSpreadSheet Class : InvalidOperation Event
Occurs when an invalid operation is performed.
Syntax
'Declaration
 
Public Event InvalidOperation As System.EventHandler(Of InvalidOperationEventArgs)
'Usage
 
Dim instance As GcSpreadSheet
Dim handler As System.EventHandler(Of InvalidOperationEventArgs)
 
AddHandler instance.InvalidOperation, handler
public event System.EventHandler<InvalidOperationEventArgs> InvalidOperation
Event Data

The event handler receives an argument of type InvalidOperationEventArgs containing data related to this event. The following InvalidOperationEventArgs properties provide information specific to this event.

PropertyDescription
Gets the context.  
Gets the description of the invalid operation.  
Gets the operation.  
Example
This example uses the InvalidOperation event.
private void gcSpreadSheet1_InvalidOperation(object sender, GrapeCity.Windows.SpreadSheet.UI.InvalidOperationEventArgs e)
        {
            listBox1.Items.Add(e.Message.ToString());
        }

private void gcSpreadSheet1_LeaveCell(object sender, GrapeCity.Windows.SpreadSheet.UI.LeaveCellEventArgs e)
        {
            listBox1.Items.Add(e.Column.ToString());
            listBox1.Items.Add(e.Row.ToString());
        }
Private Sub GcSpreadSheet1_InvalidOperation(sender As System.Object, e As GrapeCity.Windows.SpreadSheet.UI.InvalidOperationEventArgs) Handles GcSpreadSheet1.InvalidOperation
        ListBox1.Items.Add(e.Message.ToString())
    End Sub

Private Sub GcSpreadSheet1_LeaveCell(sender As System.Object, e As GrapeCity.Windows.SpreadSheet.UI.LeaveCellEventArgs) Handles GcSpreadSheet1.LeaveCell
        ListBox1.Items.Add(e.Column.ToString())
        ListBox1.Items.Add(e.Row.ToString())
    End Sub
See Also