Professional UI Solutions
Site Map   /  Register
 
 

Forum

Please Log In to post a new message or reply to an existing one. If you are not registered, please register.

NOTE: Some forums may be read-only if you are not currently subscribed to our technical support services.

Forums » Prof-UIS Tech Support » LEft top grid cell Collapse All
Subject Author Date
renier Jun 8, 2009 - 8:39 AM

Is there any way to get hold of the left top grid outer cell (i.e. the one at position (-1;-1) )?

Technical Support Jun 8, 2009 - 10:57 AM

First of all, your grid window should have at least one outer header column at top and one header row on left. If this true, then you can instantiate header cells at top/left corner:

CExtGridWnd & wndGrid = . . .
LONG nColNo = 0;   // column index relatively to part of the grid (outer header part at top/bottom/left/right, outer corner part or inner data part)
LONG nRowNo = 0;   // row index relatively to part of the grid (outer header part at top/bottom/left/right, outer corner part or inner data part)
INT nColType = -1; // -1 - header or corner area at left, 0 - middle data area, 1 - header or corner area at right
INT nRowType = -1; // -1 - header or corner area at top, 0 - middle data area, 1 - header or corner area at bottom
CExtGridCell * pCell =  wndGrid.GridCellGet( nColNo, nRowNo, nColType, nRowType, RUNTIME_CLASS( CExtGridCellHeader ) );
      pCell->TextSet( _T("top-left"));