delphi - How do i detect new columns added to a list-view control? -
i writing component descends tlistview, , want know when developer using component adds column can react. how can detect when new column added? there event?
there no such event, since component writer, events off-limits anyway. events developers using component.
columns added sending control lvm_insertcolumn
messages. override message handler in descendant control:
procedure lvminsertcolumn(var msg: tmessage); message lvm_insertcolumn;
implement call inherited handler, , whatever want.
procedure tlistviewdescendant.lvminsertcolumn(var msg: tmessage); begin inherited; // todo: custom handling end;
Comments
Post a Comment