Created 2008-04-11 08:09:37 by Nils G. Svedmyr on NILSXP [ Header and license information ]

Class List


Class cReportControlGridColumn

Source: CREPORTCONTROLGRIDCOLUMN.PKG
Baseclass: cComReportColumn


*** For internal usage ***
Subclass (wrapper) for the RecordColumn Class.
A column in a grid (a cReportControlGrid Object).
This class is used by the cReportControlGrid class.
NOTE: You would normally not instantiate this class. Instead
you would use the corresponding messages of the cReportControlGrid class,
with the 'Set/Get MessageName item iColumn to ...' syntax.
These messages has been placed here as a 'safety precaution' only;
If the wrong syntax is used in a cReportControlGrid object,
when addressing a column,
e.g. 'Set Header_Label of hColumn to "Some Text"'
...intead of the correct syntax:
'Set Header_Label item iColumn to "Some Text"',
it will still work...

Procedures

Functions

HeaderIcon Integer iIcon - Procedure Set
To set an icon for a column/header.
Syntax: Set HeaderIcon item iColumn to RC_ButtonNormal
Params:
iColumn is the column/header handle
iIcon is the in an ImageList

HeaderWidth Integer iWidth - Procedure Set
Set the width of a particular header column.
Syntax:
Set HeaderWidth to 300
Note:
If pbAutoColumnSizing=True the iWidth value passed needs to be much larger than
the actual column width to be Set.
It seems like there is some sort of ratio between the grid width and the iWidth passed.
Trial and Error seems to be the way to Set the iWidth if pbAutoColumnSizing=True.
Tip:
Set pbAutoColumnSizing=False while you work out the optimal width for each column. Then
when you are satisfied, change the setting back to True.

ColumnWidth Integer iWidth - Procedure Set
Same as Set HeaderWidth.

HeaderColumnJustificationMode Integer iMode - Procedure Set
Aligns the text (and icons) for a particular header item.
It will override the HeaderJustificationMode and pbUseColumnJustificationModeForHeader
setting that are for all header items.
Syntax:
Set HeaderColumnJustificationMode to iMode
iMode Constants:
OLExtpAlignmentLeft, OLExtpAlignmentCenter, OLExtpAlignmentRight, OLExtpAlignmentVCenter
OLExtpAlignmentWordBreak, OLExtpAlignmentTextMask, OLExtpAlignmentIconLeft, OLExtpAlignmentIconCenter
OLExtpAlignmentIconRight, OLExtpAlignmentIconTop, OLExtpAlignmentIconVCenter, OLExtpAlignmentIconBottom, OLExtpAlignmentIconMask
You may use the plus sign (+) to combine constants in an expression.
Default: OLExtpAlignmentLeft
Note: This setting will override the HeaderJustificationMode and pbUseColumnJustificationModeForHeader
which are a Global settings.

HeaderLabel String sLabel - Procedure Set
Define text for headers
Syntax:
Set HeaderLabel to "Some text"

FooterLabel String sText - Procedure Set
To set the footer text of the specified column.
Syntax:
Set FooterLabel to "Some text"
Note: The FooterVisibleState state must be true.

FooterColumnJustificationMode Integer iMode - Procedure Set
Aligns the text (and icons) for a particular footer item.
Syntax:
Set FooterColumnJustificationMode to iMode
iMode Constants:
OLExtpAlignmentLeft, OLExtpAlignmentCenter, OLExtpAlignmentRight, OLExtpAlignmentVCenter
OLExtpAlignmentWordBreak, OLExtpAlignmentTextMask, OLExtpAlignmentIconLeft, OLExtpAlignmentIconCenter
OLExtpAlignmentIconRight, OLExtpAlignmentIconTop, OLExtpAlignmentIconVCenter, OLExtpAlignmentIconBottom, OLExtpAlignmentIconMask
You may use the plus sign (+) to combine constants in an expression.
Default: OLExtpAlignmentLeft

ColumnJustificationMode Integer iMode - Procedure Set
The property can be set for a particular column, which
will override the grid level AllColumnJustificationMode setting.
Aligns the text (and icons) for all items of the passed column. (Not the header, see
HeaderColumnJustificationMode for that).
Syntax:
Set ColumnJustificationMode to OLExtpAlignmentLeft
Constants (iMode):
OLExtpAlignmentLeft, OLExtpAlignmentCenter, OLExtpAlignmentRight,
OLExtpAlignmentVCenter, OLExtpAlignmentWordBreak, OLExtpAlignmentTextMask,
OLExtpAlignmentIconLeft, OLExtpAlignmentIconCenter, OLExtpAlignmentIconRight,
OLExtpAlignmentIconTop, OLExtpAlignmentIconVCenter, OLExtpAlignmentIconBottom,
OLExtpAlignmentIconMask
Default: OLExtpAlignmentLeft

ColumnResizable Boolean bState - Procedure Set
Specifies whether a grid column can be resized by dragging the header divider.
Syntax:
Set ColumnResizable to True/False
Default: True
Note: There is also a 'global' grid level ResizeColumnState property.

HeaderToolTip String sToolTip - Procedure Set
Set the tooltip for a column
Syntax:
Set HeaderToolTip to "Some Header tooltip text"

ColumnEditControlStyle Integer iStyle - Procedure Set
To set which edit mode should be used for items/cells in a column.
Syntax:
Set ColumnEditControlStyle to iStyle
Constants for iStyle:
RC_WordBreak Breaks words. The style automatically breaks lines between
words if a word would extend past the edge of the item rectangle.
RC_Single_Line Displays text on a single line only.
RC_Numeric Numeric digits only.
RC_Read_Only Do not allow to edit.
Note:
The property grid level pbSelectTextOnEdit or the pbColumnSelectTextOnEdit property
for the passed column number must be True for this Property to have any effect.
See Also: Specialized versions of this message; ColumnWordbreakState,
ColumnCapsLockState and ColumnNumericState.

ColumnCapsLockState Boolean bState - Procedure Set
Determines if all text entered to this column from the keyboard will be
converted to upper Case.
Syntax:
Set ColumnCapsLockState to True/False
Note: The setting will _not_ format existing text, it will only control
how text can be entered into items/cells for the passed column number.

ColumnWordbreakState Boolean bState - Procedure Set
Breaks words for all items/cells in the passed column when in edit mode.
The style automatically breaks lines between words if a word would extend
past the edge of the item rectangle.
Syntax:
Set ColumnWordbreakState to True/False

ColumnNumericState Boolean bState - Procedure Set
Determines if all text entered to this column from the keyboard will be
numeric only.
Syntax:
Set ColumnNumericState to True/False
Note: It will also set the justification mode to Right.

pbColumnSelectTextOnEdit Boolean bState - Procedure Set
Column variant of the 'global' grid level property pbSelectTextOnEdit.
It can be used to override the pbSelectTextOnEdit setting for a particular
column.
Syntax:
Set pbColumnSelectTextOnEdit to True/False

ColumnAutoSize Boolean bState - Procedure Set
Specifies if column auto sizing is on or off.
Syntax:
Set ColumnAutoSize to True/False
NOTE: When a column is added, the resizable parameter is used to set the value for
BOTH the Resizable and AutoSize Property. If these properties will have a
different value, then you will have to change the required value after the
column has been added. I.e. When the column was added you specified that
Resizable=True, If you require that Autosize = False then you need to Add code
to change this.

ColumnEntryState Boolean bState - Procedure Set
Determines if a whole column can be edited or not.
Note: There are actually three different levels that can be used to
regulate if items/cells can be edited or not.
1. Set pbAllowEdit at grid level (global for the entire grid)
2. 'Set ColumnEntryState item iColumn to True/FALSE' at column
level will override the pbAllowEdit setting.
3. 'Set EntryState item iItem to True/FALSE' at item
level will override both the pbAllowEdit and EntryState
setting at column level.
Syntax:
Set ColumnEntryState to bState

ColumnShadowState Integer iColumn Boolean bState - Procedure Set
Same as Set ColumnEntryState. To be compatable with the Column_Shadow_State
of the VDF DataList class (That is used by the VDF Grid class).
Syntax:
Set ColumnShadowState to True/False

ColumnComboState Boolean bState - Procedure Set
Specifies whether a column of a grid is presented as a combo form.
Syntax:
Set ColumnComboState to True/False

ColumnComboEntryState Boolean bState - Procedure Set
Determines if column allows entry into the cell or only allows selection
of values from list.
Syntax:
Set ColumnComboEntryState to True/False

ColumnPromptMode Boolean bState - Procedure Set
Specifies whether a column of a grid is presented with a prompt button.
Syntax:
Set ColumnPromptMode to True/False

ColumnMaxLength Integer iLength - Procedure Set
To set the maximum number of characters that can be entered into
the passed column.
This will be of more interest for a db aware class variant.

pbColumnSortable Boolean bState - Procedure Set
To set if a particular column should be sortable.
Syntax:
Set pbColumnSortable to True/False
Note: There is also a grid level property 'pbAllowAllColumnSort'
If the pbColumnSortable property is used it will
override the pbAllowAllColumnSort setting.

pbColumnVisible Boolean bState - Procedure Set
To set if a particular column should be visible or not.
Syntax:
Set pbColumnVisible to TRUE/False
Note: See also 'pbShowColumnInFieldChooser'
Depending on that setting, this column (if set to False) will be available
or not in the FieldChooser object.

pbShowColumnInFieldChooser Boolean bState - Procedure Set
Indicates if a particular column will appear in the FieldChooser when the column
is hidden or in the "Group By Box."
Syntax:
Set pbShowColumnInFieldChooser to True/False
Note: There is also a pbShowAllColumnsInFieldChooser property at grid level that
will be used for each column where this message is not used.

ColumnItemIndex Integer iValue - Procedure Set
This is the Index of the column given when added to the ReportControl's collection
of columns. The ItemIndex starts at 0 and increments by 1 for each column in the
ReportControl. The ItemIndex will not change when the columns are moved (dragged and
dropped to another location).
The ItemIndex is used to Find and return a reference to a column. Since the Index of
the column might change frequently, the ItemIndex is used when the column needs to be
accessed.

HeaderIcon Returns Integer - Function
Syntax: Get HeaderIcon to iIconNumber

HeaderWidth Returns Integer - Function
Get the width of a particular header column.
Syntax:
Get HeaderWidth to Integer

ColumnWidth Returns Integer - Function
Same as Set HeaderWidth.

HeaderColumnJustificationMode Returns Integer - Function
See: Procedure Set HeaderColumnJustificationMode for an explanation.

HeaderLabel Returns String - Function
Get the text for a header
Syntax:
Get HeaderLabel to sString

FooterLabel Returns String - Function
See: Procedure Set FooterLabel for an explanation.

FooterColumnJustificationMode Returns Integer - Function
See: Procedure Set FooterColumnJustificationMode for an explanation.

ColumnResizable Returns Boolean - Function
See: Set ColumnResizable for an explanation.

HeaderToolTip Returns String - Function
Get the tooltip of a particular header item.
Syntax:
Get HeaderToolTip to sString

ColumnEditControlStyle Returns Integer - Function
See: Set ColumnEditControlStyle for an explanation.

IsEditOptionsObjectConnected Integer iColumn Returns Handle - Function
Helper function for e.g. ColumnEditControlstyle.
Returns a handle to the ItemEditOptions object (VDF-side)
if it was successfull in connecting.
If unsuccessfull it Returns 0.

pbColumnSelectTextOnEdit Returns Boolean - Function
See: Set pbColumnSelectTextOnEdit for an explanation.

ColumnAutoSize Returns Boolean - Function
See: Procedure Set ColumnAutoSize for an explanation.

ColumnEntryState Returns Boolean - Function
See: Set ColumnEntryState for an explanation.

ColumnShadowState Returns Boolean - Function
Syntax: Get ColumnShadowState item iColumn to bState
See: Set ColumnShadowState for an explanation.

pbColumnSortable Returns Boolean - Function
See: Procedure Set pbColumnSortable for an explanation.

pbColumnVisible Returns Boolean - Function
See procedure Set pbColumnVisible for an explanation.

pbShowColumnInFieldChooser Returns Boolean - Function
See procedure Set pbShowColumnInFieldChooser for an explanation.

ColumnItemIndex Returns Integer - Function
See procedure Set ColumnItemIndex for an explanation.

ColumnFind Integer iIndex Returns Variant - Function
Searches the collection of columns sequentially to find the first column matching
the specified ItemIndex. If no matching Found, NULL is returned.


Header and license information

****************************************************************************
$Module type: CLASS
$Module name: cReportControlGridColumn.pkg
$Author : Nils G. Svedmyr
Created : 2008-03-14 @ 17:56
Description : A wrapper class for the Report Control's cComReportColumn.
The class is used internally by the class cReportControlGrid.
$Rev History
2008-03-14 Module header created
****************************************************************************
Note: If you don't have version 11.2.2 of the Report Control, you may use the 11.2.1 instead.
Of course you cannot Use both packages at the same time.
If you Use version 11.2.1 you wont be able to use the piWatermarkAlignment function
(If you have Set it in your code, it will be ignored.)
Use Codejock.ReportControl.v11.2.1.pkg