The C1TrueDBGrid Designer can be accessed either through the C1TrueDBGrid Tasks menu, the Columns property, or the context menu. To access the C1TrueDBGrid Designer through the C1TrueDBGrid Tasks menu, you can click the smart tag in the upper right corner of C1TrueDBGrid to open the C1TrueDBGrid Tasks menu, and then select the Designer option. Also, to access the C1TrueDBGrid Designer through the Columns property, you can click the ellipsis button next to the Columns property in the Properties window. To access the C1TrueDBGrid Designer through the context menu, you can right-click the C1TrueDBGrid control on the form and then select Design from the context menu.
This designer allows grid columns to be set up easily at design time instead of having to write the code. Just select the grid, then right-click to bring up the context menu, and then click the Design menu item. This will bring up the C1TrueDBGrid Designer shown below:
The editor displays the grid columns in a window on the right and the properties for these columns on the left. The tabs above the Properties window define which set of properties, DataColumn, DisplayColumn, or Split, are displayed in the properties grid.The editor performs the following actions:
Element | Description |
---|---|
These tabs above the property grid determine which set of properties are available for modification in the designer. The tabs allow you to choose between the DataColumns property set that contains data-related column properties, the DisplayColumns property set that contains display-related column properties, and the Split property set that contains split-related properties. | |
These buttons set the column widths for the grid. The left button sets all the columns to have the same width, the center button increases the width of the selected column (the column with focus in the grid), and the right button decreases the width of the selected column (the column with focus in the grid). | |
These buttons add, insert, and delete columns from the grid. The first adds columns to the grid, the second button inserts columns in the grid, and the third button deletes columns from the grid. | |
The drop-down box sets which column receives focus. By choosing a column from the drop-down list, the associated properties for this column will appear in the property grid to the left. | |
These buttons set the vertical alignment of the selected column. The first button aligns all column content to the top. The second button aligns all column content to the center, and the third button aligns all column content to the bottom. | |
Align column content to the left, center, or right. These buttons only affect the scrollable area of the grid. To set the alignment for the header columns, select the columns and set the TextAlignFixed property. | |
These buttons add or remove vertical or horizontal splits. The first button adds a vertical split to the grid, while the second one adds a horizontal split. The third button removes a vertical split, while the fourth one removes a horizontal split. | |
These buttons set the DataView property of the table. The buttons set the DataView property to Normal, GroupBy, Hierarchial, Inverted, Form, MultipleLines, and MultipleLinesFixed, respectively. See Views for more information. |
There are three types of properties enumerated in the TrueDBGridDesigner:
The following SplitCollection object properties are available in the C1TrueDBGrid Designer through the Split tab:
Property | Description |
---|---|
AllowColMove | Gets or sets a value indicating the ability to move columns. |
AllowColSelect | Gets or sets a value indicating the ability to select columns. |
AllowFocus | Gets or sets a value indicating whether the split can receive focus. |
AllowHorizontalSizing | Gets or sets a value indicating whether a user is allowed to resize horizontal splits. |
AllowRowSelect | Gets or sets a value indicating the ability to select rows. |
AllowRowSizing | Gets or sets how interactive row resizing is performed. |
AllowVerticalSizing | Gets or sets a value indicating whether a user is allowed to resize vertical splits. |
AlternatingRowStyle | Gets or sets a value indicating whether the split uses the OddRowStyle for odd-numbered rows and EvenRowStyle for even-numbered rows. |
BorderStyle | Gets or sets the type of border rendered for a split. |
Caption | Gets or sets the caption. |
CaptionHeight | Gets or sets the height of the caption. |
CaptionStyle | Gets or sets the Style object that controls the appearance of the caption area. |
ColumnCaptionHeight | Gets or sets the height of the column captions. |
ColumnFooterHeight | Gets or sets the height of column footers. |
DisplayColumns | Gets a collection of C1DisplayColumn objects. |
EditorStyle | Gets or sets the Style object that controls the appearance of the cell editor within a grid. |
EvenRowStyle | Gets or sets the Style object that controls the appearance of an even-numbered row when using AlternatingRows. |
ExtendRightColumn | Gets or sets a value that determines how the last column will extend to fill the dead area of the split. |
FetchRowStyles | Gets or sets a value indicating whether the FetchRowStyle event will be raised. |
FilterBar | Gets or sets a value indicating the visibility of the FilterBar. |
FilterBarStyle | Gets or sets the Style object that controls the appearance of the FilterBar. |
FilterBorderStyle | Controls the appearance of the separator for the FilterBar. |
FooterStyle | Gets or sets the Style object that controls the appearance of column footers. |
HeadingStyle | Gets or sets the Style object that controls the appearance of the grids column headers. |
Height | Gets or sets the height of a split. |
HighlightRowStyle | Gets or sets the Style object that controls the current row/cell when the MarqueeStyle is set to Highlight Row/Cell. |
HorizontalScrollGroup | Gets or sets the group which synchronizes horizontal scrolling between splits. |
HScrollBar | Gets the HBar object that controls the appearance of the horizontal scroll bar. |
InactiveStyle | Gets or sets the Style object that controls the grids caption when it doesn't have focus. |
Locked | Gets or sets a value indicating if the cells of a split can be edited. |
MarqueeStyle | Gets or sets the MarqueeStyle for a Split. |
MinHeight | Gets or sets the minimum height that a split can be interactively resized. |
MinWidth | Gets or sets the minimum width that a split can be interactively resized. |
Name | Gets or sets the name of a split. |
OddRowStyle | Gets or sets the Style object that controls the appearance of an odd-numbered row when using AlternatingRows. |
RecordSelectors | Gets or sets a value indicating the visibility of row headers for Split. |
RecordSelectorStyle | Gets or sets the Style object that controls the appearance of the RecordSelectors. |
RecordSelectorWidth | Gets or sets the width of the row headers. |
SelectedStyle | Gets or sets the Style object that controls the appearance of selected rows and columns. |
SplitSize | Gets or sets the size of a split. |
SplitSizeMode | Gets or sets a value indicating how the SplitSize property is used to determine the actual size of a split. |
SpringMode | Gets or sets a value that determines how columns will resize when the grid is resized. |
Style | Gets or sets the root Style object for the Split. |
VerticalScrollGroup | Gets or sets the group which synchronizes vertical scrolling between splits. |
VScrollBar | Gets the VBar object that controls the appearance of the vertical scroll bar. |
The following C1DataColumnCollection object properties are available in the C1TrueDBGrid Designer through the Column tab:
Property |
Description |
---|---|
Gets or sets the type of aggregate computed for a grouped row. |
|
Gets or sets the image shown in a drop-down button in a column. |
|
Gets or sets the text in the column header. |
|
Gets or sets the database field name for a column. |
|
Gets or sets the maximum number of characters which may be entered for cells in this column. |
|
Gets or sets the default value for a column when a new row is added by the grid. |
|
Gets or sets the C1TrueDBDropDown control associated with this column. |
|
Gets or sets the edit mask for a column. |
|
Gets or sets a value indicating whether literal characters in the edit mask are stored to the underlying data source. |
|
Gets or sets the characters that should be escaped when applying the filter criteria to the data source. |
|
Gets or sets the image show in the filter button for the column. |
|
Gets or sets a value indicating whether a drop-down list is displayed in the filter cell that lists all the values of the field. |
|
Gets or sets the characters that should be escaped when applying the filter criteria to the data source. |
|
Gets or sets the key used to initiate the filtering operation as the user types in the FilterBar. |
|
Gets or sets the operator that is used for a filter expression. |
|
Gets or sets the data associated with the value of the filter for a column. |
|
Gets or sets the text displayed in the column footer. |
|
Gets or sets the GroupInfo associated with this column. |
|
Gets or sets the level of this column in a hierarchical data source. |
|
Gets or sets the formatting string for a column. |
|
Gets or sets the state of the sorting glyph in the column caption. |
|
Gets the ValueItems object for this column. |
The following C1DisplayColumnCollection object properties are available in the C1TrueDBGrid Designer through the Display Column tab:
Property | Description |
---|---|
AllowFocus | Gets or sets a value indicating the ability of a column to receive focus. |
AllowSizing | Gets or sets a value indicating whether column resizing is allowed. |
AutoComplete | Gets or sets a value indicating whether the drop-down auto fills the edit portion with the matched entry. |
AutoDropDown | Gets or sets a value indicating whether the drop-down opens automatically when a key is typed. |
Button | Gets or sets a value indicating whether a drop-down button will be displayed in this column. |
ButtonAlways | Gets or sets a value indicating whether buttons will be displayed when the cell does not contain focus. |
ButtonFooter | Gets or sets a value indicating whether a column footer will act like a button. |
ButtonHeader | Gets or sets a value indicating whether a column header will act like a button. |
ButtonText | Gets or sets a value indicating whether cells in this column look like buttons. |
ColumnDivider | Gets or sets the style of the border drawn between columns. |
DropDownList | Gets or sets a value indicating whether the drop-down acts like a drop-down list (text portion is not editable). |
EditorStyle | Gets or sets the Style used for the cell editor. |
FetchStyle | Gets or sets a value indicating whether the FetchCellStyle event will be raised for a column. |
FilterButton | Gets or sets a value indicating whether a drop-down button will be displayed in this column. |
FooterDivider | Gets or sets a value indicating whether to display the column divider in the footer area. |
FooterStyle | Gets or sets the Style object that controls the appearance of column footers. |
Frozen | Gets or sets a value indicating whether the column scrolls. |
GroupFooterStyle | Gets or sets the Style used to render the cell in the grouped footer row. |
GroupHeaderStyle | Gets or sets the Style used to render the cell in the grouped header row. |
HeaderDivider | Gets or sets a value indicating whether to display the column divider in the header area. |
HeadingStyle | Gets or sets the Style that controls the appearance of the column headers. |
Height | Gets or sets the height of the column. |
Locked | Gets or sets a value indicating whether editing is permitted in a column. |
Merge | Gets or sets a value indicating whether contiguous like-value cells of this column are merged into one large cell. |
MinWidth | Gets or sets the minimum width a column can be resized to when in SpringMode. |
Name | Gets the caption of the associated C1DataColumn objects. |
OwnerDraw | Gets or sets a value indicating whether cells in this column are drawn by the user in the OwnerDrawCell event. |
Style | Gets or sets the root Style for this column. |
Visible | Gets or sets a value indicating the visibility of a column. |
Width | Gets or sets the width of a column. |