ReoGrid provides settings for workbook WorkbookSettings and settings for every worksheet WorksheetSettings. By using settings, it is possible to change many default behavior for workbook and worksheet.
Workbook Settings
Settings of workbook can be changed by invoke SetSettings, EnableSettings, DisableSettings method of workbook instance:
// Set settings
reoGridControl.SetSettings(WorkbookSettings settings, bool enabled);
reoGridControl.EnableSettings(WorkbookSettings settings);
reoGridControl.DisableSettings(WorkbookSettings settings);
// Get settings
bool value = reoGridControl.HasSetting(WorkbookSettings settings);
Appearance
| View_ShowSheetTabControl | Allow to show sheet tab control |
|---|---|
| View_ShowScrollsShow | Allow to show all scroll bars |
| View_ShowHorScrollShow | Allow to show horizontal scroll bar |
| View_ShowVerScrollShow | Allow to show vertical scroll bar |
Script Extension (only available in Extension Package)
| Script_AutoRunOnload | Determine whether or not to run script instantly after workbook or worksheet is loaded from resource |
|---|---|
| Script_PromptBeforeAutoRun | Prompt message to end-user before run script from workbook if it is loaded from resource |
Worksheet Settings
Settings of worksheet can be changed by invoke SetSettings, EnableSettings, DisableSettings method of worksheet instance:
var worksheet = reoGridControl.CurrentWorksheet;
// Set settings
worksheet.SetSettings(WorksheetSettings settings, bool enabled);
worksheet.EnableSettings(WorksheetSettings settings);
worksheet.DisableSettings(WorksheetSettings settings);
// Get settings
bool value = reoGridControl.HasSetting(WorksheetSettings settings);
Settings of worksheet have the following items:
Behavior
| Setting | Desc |
|---|---|
| Behavior_DoubleClickToFitRowHeight | Allow double click to fit row height |
| Behavior_DoubleClickToFitColumnWidth | Allow double click to fit column width |
| Behavior_MouseWheelToScroll | Allow scroll worksheet by wheeling mouse |
| Behavior_MouseWheelToZoom | Allow zoom worksheet by wheeling mouse |
| Behavior_ShortcutKeyToZoom | Allow zoom worksheet by shortcut-keys (Ctrl + plus/minus) |
| Behavior_DragToMoveCells | Allow move or copy selected range by dragging mouse |
| Behavior_DragToMoveColumnHeader | Allow user to move entire column by dragging mouse (Reserved) |
| Behavior_ScrollToFocusCell | Allow always by scrolling worksheet to keep focused cell visibile |
| Behavior_AllowUserChangingPageBreaks | Allow user to insert, remove or adjust the page-breaks by mouse |
Editing
| Setting | Desc |
|---|---|
| Edit_Readonly | Indicates that worksheet works in read-only mode. Any changes will not be allowed |
| Edit_AutoFormatCell | Allow format data after text edited or inputed by end-user |
| Edit_FriendlyPercentInput | Allow to display a percent symbol when user inputting data inside percent-format cell |
| Edit_AutoAdjustRowHeight | Allow adjusting the height of row when user enlarges font of cell |
| Edit_AllowAdjustRowHeight | Allows user to adjust height of row by dragging mouse |
| Edit_AllowAdjustColumnWidth | Allows user to adjust the width of column by dragging mouse |
| Edit_DragSelectionToMoveCells | Allows user drags and drops the selection to move cell content |
| Edit_DragSelectionToFillSerial | Allows user to fill ranges by dragging mouse |
Appearance
| Setting | Desc |
|---|---|
| View_ShowColumnHeader | Show column headers |
| View_ShowRowHeader | Show row headers |
| View_ShowHorizontalRuler | Show ruler in horizontal direction (Reserved) |
| View_ShowVerticalRuler | Show ruler in vertical direction (Reserved) |
| View_ShowGuideLine | Show guide lines |
| View_ShowHiddenCellLine | Allow to show a single line on hidden rows header |
| View_AllowShowRowOutlines | Allow to show row outlines if outlines exiting |
| View_AllowShowColumnOutlines | Allow to show column outlines if outlines exiting |
| View_ShowPageBreaks | Allow to show page-break lines |
| View_AllowCellTextOverflow | Make cell's text only displayed inside cell, don't overlay over neighbor cells |
| View_ShowPrintAreasEnable | Showing boundary lines of printing areas |
Formula Calculation
| Setting | Desc |
|---|---|
| Formula_AutoUpdateReferenceCell | Allow to update formula reference cells automatically |
| Formula_AutoPickingAddress | Allow to select and pick an address from worksheet during formula edit |
| Formula_AutoFormat | Allow to correct, format and rebuild formula automatically |