I have a need for event StringGrid1HeaderClick(), which I wanted to develop next.Why develop? It's already there...
But this event is called, even if I make a double-click! How do I prevent StringGrid1HeaderClick() to react on a double-click?In the same way as shown above?
Or how to distinguish between double- and single-click?I suppose you need a timer, its interval is a bit longer than the double-click interval. In MouseDown and MouseUp you take actions to avoid firing the OnClick event, but trigger the timer. The OnClick, instead, is fired in timer's OnTimer event. If you disable the timer in the DblClick method the OnClick never happens in case of a DblClick.