CTools Add method
Posted: Tue Mar 10, 2009 8:18 pm
I'm adding 2 tools to my chart (CrossHair Cursor and Mark Tips) with the following code:
long nInt1 = m_SelectedChart->GetTools().Add(tcCursor);
long nInt2 = m_SelectedChart->GetTools().Add(tcMarksTip);
What is the long returned by the Add method? Is it the position in the list of Tools? Or is it the tooltype (tcCursor or tcMarksTip)
Later I delete these tools from the ToolsList on the chart. If I don't have any other tools present, I delete the first 2 tools in the ToolsList. But if I have other tools present, how do I know which position in the list to delete?
m_SelectedChart->GetTools().Delete(???) What is the index I use here?
Thanks.
long nInt1 = m_SelectedChart->GetTools().Add(tcCursor);
long nInt2 = m_SelectedChart->GetTools().Add(tcMarksTip);
What is the long returned by the Add method? Is it the position in the list of Tools? Or is it the tooltype (tcCursor or tcMarksTip)
Later I delete these tools from the ToolsList on the chart. If I don't have any other tools present, I delete the first 2 tools in the ToolsList. But if I have other tools present, how do I know which position in the list to delete?
m_SelectedChart->GetTools().Delete(???) What is the index I use here?
Thanks.