Page 1 of 1

OnDblClick event

Posted: Wed Dec 05, 2007 10:04 am
by 9084141
I am using TChart's OnDblClick event in C++ to launch the editor using ShowEditor(). This works fine. However, when I close the editor, the chart is now waiting for a second click to define a zoom window. On clicking the chart goes into zoom mode.

The chart has obviously recorded the first click of the dblclick as a mouse down event and on return from the editor is waiting for a mouseup event to complete the definition of the zoom area.

How do I stop this irritating behaviour? :evil:

Posted: Wed Dec 05, 2007 11:42 am
by narcis
Hi MoGulZA,

You can try disabling zoom before opening the editor and enable it again after closing it, for example:

Code: Select all

    TChart1.Zoom.Enable = False

OnDblClick event

Posted: Fri Dec 07, 2007 11:51 am
by 9084141
Hi Narcis,

I've tried that ... does not work ..... Any other suggestions?

Posted: Mon Dec 10, 2007 12:09 pm
by Pep
Hi,
how about using :
void CNeilDlg::OnOnDblClickTchart1()
{
m_chart.ShowEditor(-1);
}

?

Posted: Mon Dec 10, 2007 1:59 pm
by 9084141
Thanks! That worked !! Don't understand why there should be a difference but I'm sure you'll sort that out !!!