Objective Grid: Static edit cells

Article ID: 225
Last updated: 11 Jun, 2018
Article ID: 225
Last updated: 11 Jun, 2018
Revision: 3
Views: 1818
Posted: 11 Jan, 2001
by Meltreger B.
Updated: 11 Jun, 2018
by Meltreger B.

Problem


When the user clicks on a cell it switches into edit-mode. Is there some way to make cells static?


Cause



Action


You can use the CGXStatic control. It is recommended that you also set the cell read only so the user cannot paste data into the cell or accidentally press DELETE and clear the cell.

Example:

SetStyleRange(CGXRange(1,1,CAL_ROWS,CAL_COLS),
CGXStyle( )
.SetControl(GX_IDS_CTRL_STATIC)
.SetReadOnly(TRUE)
.SetFont(CGXFont( ).SetBold(TRUE).SetSize(10))
.SetInterior(RGB(192,192,192))
.SetHorizontalAlignment(DT_CENTER)
.SetVerticalAlignment(DT_VCENTER)
);

This article was:   Helpful | Not helpful
Report an issue
Article ID: 225
Last updated: 11 Jun, 2018
Revision: 3
Views: 1818
Posted: 11 Jan, 2001 by Meltreger B.
Updated: 11 Jun, 2018 by Meltreger B.

Others in this category