Dispatch IDs for events generated by TChart
Posted: Mon Jul 27, 2015 11:07 pm
I am trying to add an OnAfterDraw event to my TChart that is placed on my form at runtime. I want to add an OnAfterDraw method. Where can I find the dispatch ID of the OnAfterDraw event so I can add the event handler? In the past I have added handlers for OnMouseDown, OnMouseUp and OnMouseMove with IDs 19, 21 and 20 respectively. It was a while ago and can't recall where I got these IDs as well as the list of paramenters (VTS_XX) . e.g. here is the snippet of code I used before where the ControlIDs for the added charts start at 99:
Code: Select all
BEGIN_EVENTSINK_MAP(CPageDlg, CPropertyPage)
//{{AFX_EVENTSINK_MAP(CPltPage)
ON_EVENT_RANGE(CPageDlg, 99, 200, 19 /* OnMouseDown */, OnMouseDownTchart1, VTS_I4 VTS_I4 VTS_I4 VTS_I4 VTS_I4)
ON_EVENT_RANGE(CPageDlg, 99, 200, 20 /* OnMouseMove */, OnOnMouseMoveTchart1, VTS_I4 VTS_I4 VTS_I4 VTS_I4)
ON_EVENT_RANGE(CPageDlg, 99, 200, 21 /* OnMouseUp */, OnOnMouseUpTchart1, VTS_I4 VTS_I4 VTS_I4 VTS_I4 VTS_I4)
//}}AFX_EVENTSINK_MAP
END_EVENTSINK_MAP()