OnCellImageClick

Class: TEgDBGridEx

property OnCellImageClick: TEgDBGridCellImageClick;

Fired instead of the native OnCellClick when a data-cell click lands on that column’s ImageIndex icon (drawn by the same logic as OnBeforeDrawCell’s own ImageIndex/ImageAlignment). See TEgDBGridCellImageClick.

This is a deliberate exception: every other title/cell click pair in this unit (for example OnTitleImageClick) always lets its native counterpart fire too, and only suppresses its own custom companion event. OnCellImageClick instead replaces OnCellClick outright for that one click - the native event does not fire alongside it.

Also available at column level (see TEgColumn.OnCellImageClick); when both are assigned, the grid-level handler runs first.

Scope

Never a checkbox column, which never shows this icon at all. For every other column kind, this covers ImageIndex exactly as it is actually drawn - including the graphic/BLOB overlay case:

Gating

The icon’s ImageIndex/ImageAlignment are resolved exactly as they would be drawn - including whatever OnBeforeDrawCell changes them to - without actually painting anything. This means:

Edit mode

A click on the icon never leaves the cell in edit mode, even where a second click on an already-current cell would normally open the in-place editor.

See Also

(C) 2026 Easygate, Lda