property Items.SplitCell ([Item as Variant], [ColIndex as Variant]) as Variant
Splits a cell, and returns the inner created cell.

 TypeDescription 
   Item as Variant A long expression that indicates the handle of the item where a cell is being divided, or 0. If the Item parameter is 0, the ColIndex parameter must indicate the handle of the cell.  
   ColIndex as Variant A long expression that indicates the index of the column where a cell is divided, or a long expression that indicates the handle of the cell being divided, if the Item parameter is missing or it is zero.  
   Variant A long expression that indicates the handle of the cell being created.  
The SplitCell method splits a cell in two cells. The newly created cell is called inner cell. The SplitCell method always returns the handle of the inner cell. If the cell is already divided using the SplitCell method, it returns the handle of the inner cell without creating a new inner cell. You can split an inner cell too, and so you can have a master cell divided in multiple cells. Use the CellWidth property to specify the width of the inner cell. Use the CellCaption property to assign a caption to a cell. Use the InnerCell property to access an inner cell giving its index. Use the CellParent property to get the parent of the inner cell. Use the CellItem property to get the owner of the cell. Use the UnsplitCell method  to remove the inner cell if it exists. Use the MergeCells property to combine two or more cells in a single cell.

( "Merge" means multiple cells in a single cell, "Split" means multiple cells inside a single cell )

(the picture shows a cell that's divided in three cells)

The following sample shows how to split a cell in three cells:

 

(the picture shows a cell without being divided)

 


Send comments on this topic.
1999-2015 Exontrol.COM, Software. All rights reserved.