Skip to main content

TdxCustomTileControl.OnGroupRemoveWithLastItem Event

Enables you to prevent automatic tile group destruction when its last item is removed or destroyed.

Declaration

property OnGroupRemoveWithLastItem: TdxTileControlGroupRemoveWithLastItemEvent read; write;

Remarks

This event occurs every time the last item in a group is removed or deleted, and the control is about to delete the emptied group automatically. You can assign False to the AAllow parameter within an OnGroupRemoveWithLastItem event handler to keep the emptied group accessible via the AGroup parameter.

For instance, you can preserve emptied named groups (that is, groups with captions):

procedure TMyForm.dxTileControl1GroupRemoveWithLastItem(Sender: TdxCustomTileControl; AGroup: TdxTileControlGroup; var AAllow: Boolean);
begin
  AAllow := AGroup.Caption.Text = '';  // Allows automatic deletion for all groups without an assigned caption text
end;

Refer to the TdxTileControlGroupRemoveWithLastItem procedural type description for detailed information on all parameters accessible within an OnGroupRemoveWithLastItem event handler.

See Also