FlexGrid for WinForms | ComponentOne
C1.Win.C1FlexGrid Namespace / C1FlexGridBase Class / StartEdit Event

In This Topic
    StartEdit Event (C1FlexGridBase)
    In This Topic
    Fires before the control enters edit mode.
    Syntax
    'Declaration
     
    
    Public Event StartEdit As RowColEventHandler
    public event RowColEventHandler StartEdit
    Event Data

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

    PropertyDescription
    Gets or sets a value indicating whether the operation should be canceled.  
    Gets the index of the column that caused the event.  
    Gets the index of the row that caused the event.  
    Remarks

    This event fires before the control enters edit mode. It allows you to prevent editing by setting the Cancel parameter to true, or to supply a list of choices for a combo list using the ComboList property, or an edit mask using the EditMask property.

    If the choices or the mask are the same for a whole column, you may set them more efficiently using the RowCol.ComboList and RowCol.EditMask properties for the Column object. In this case, there's no need to handle the StartEdit event at all.

    The grid also exposes a BeforeEdit event. The difference between the two is that BeforeEdit fires when the grid paints the cell that has the focus (so it can determine whether the cell has a drop-down button). BeforeEdit fires more often than StartEdit, and does not always indicate that the grid is actually entering edit mode.

    See Also