For several editable cell types (the ones in Working with Editable Cell Types), when you click inside the cell, an editor is displayed. You can go beyond this simple line editor and provide a custom user interface (to provide options to make the task of user input easier). This other level of interface is controlled by the subeditor, or the editor within the cell editor. For example, when you select the date-time cell, you can provide a calendar for the user to select a date. This calendar control would be called by the subeditor.
You can create your own subeditor, which can be displayed by the following actions:
The steps for creating your own subeditor are:
To see an example of a subeditor, refer to Customizing the Pop-Up Date-Time Control where the calendar subeditor is available for a date-time cell, and Customizing the Pop-Up Calculator Control where a calculator subeditor is available for several numeric cell types.
For several editable cell types, when you click inside the cell, a subeditor is displayed by default. But sometimes you might want to disable these subeditors. For example, in date-time cells you might want to disable the pop-up calendar control; in the number cells, you might want to disable the pop-up calculator control.
To cancel subeditors, you can set e.Cancel to True in the SubEditorOpening event, as shown in the following example.
C# |
Copy Code
|
---|---|
private void fpSpread1_SubEditorOpening(object sender, FarPoint.Win.Spread.SubEditorOpeningEventArgs e) { e.Cancel = true; } |
VB |
Copy Code
|
---|---|
Private Sub fpSpread1_SubEditorOpening(ByVal sender As Object, ByVal e As FarPoint.Win.Spread.SubEditorOpeningEventArgs) Handles FpSpread1.SubEditorOpening e.Cancel = True End Sub |
For information on the editable cell types, refer to Working with Editable Cell Types.
For information on other features of cell types, refer to Understanding Additional Features of Cell Types.