I need to get the index of the position of a cursor at an unknown x or y value. I can get the rest and I seen a GetCursorValueIndex function with the Series Heirarchy and tried it but it didnt return what I needed.
Any ideas?
Thanks,
Tom
Get Index of Cursor at unknown X or Y Value?
-
- Site Admin
- Posts: 14730
- Joined: Mon Jun 09, 2003 4:00 am
- Location: Banyoles, Catalonia
- Contact:
Hi Tom,
What about doing something as I suggested here in TCursorTool's OnChange event? OnChange's ValueIndex parameter only has valid values when the cursor is set to snap.
What about doing something as I suggested here in TCursorTool's OnChange event? OnChange's ValueIndex parameter only has valid values when the cursor is set to snap.
Best Regards,
Narcís Calvet / Development & Support Steema Software Avinguda Montilivi 33, 17003 Girona, Catalonia Tel: 34 972 218 797 http://www.steema.com |
Instructions - How to post in this forum |
Yeah I used this code below for the on change event in the cursor:narcis wrote:Hi Tom,
What about doing something as I suggested here in TCursorTool's OnChange event? OnChange's ValueIndex parameter only has valid values when the cursor is set to snap.
Code: Select all
curpos: Integer;
curpos := Chart1.Series[seriesidx].XValues.Locate(XValue);
Thanks,
Tom
Tom