<< Return to Main Index

< Return to Class Index

CGXGridCore::CanMergeCells

virtual BOOL CanMergeCells(const CGXStyle& style1, const CGXStyle& style2);

style1

Const reference to the style object of the first cell.

style2

Const reference to the style object of the neighboring cell.

Return Value

TRUE if the cells can be merged; FALSE otherwise.

Remarks

This virtual method is called to determine if two neighboring cells can be merged.

The default implementation of the methods checks if the GX_MERGE_COMPVALUE has been set with CGXStyle::SetMergeCell.

If this is the case, the method compares the values of the two style objects and returns TRUE if both values are equal. Otherwise it will compare all style information.

Control-Factory Specific ->

This method has been implemented using the abstraction mechanism as discussed in the chapter "Reducing the size of your application" in the user's guide. A call to the ImplementMergeCells method from within the control factory class' InitializeGridComponents method will make the concrete implementation of this method available to your application.

If no concrete implementation is available this method returns FALSE. No action is performed.

END Control-Factory Specific

See Also

CGXGridCore::SetMergeCellsMode CGXStyle::SetMergeCell

CGXGridCore

Class Overview | Class Members