"You do not say if this is something you want continuously displayed, or just for a selected point. Continuously retrieving this information using the above method my result in a big performance hit though"
That's exactly my problem. I'd like to display this data continously, when the user is moving moving a cursor (not the mouse-cursor, a special vertical line that i inserted) over the chart.
but this line will only be moved in situations, when the user wants to determine the curves values with this line. I will try and do this with these methods and test the performance.
regards
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
This allows the X and Y coordinates of the mouse to display in a status bar. It should be possible to modify this to provide you with the LineItem Y value. There are a number of methods that you could use to do this from the method described on the above link, to capturing the X value and iterating the PointPairList/DataSourcePointPairList to find the index of the captured X value. From here you can retrieve the Y value from the underlying datasource.
You do not say if this is something you want continuously displayed, or just for a selected point. Continuously retrieving this information using the above method my result in a big performance hit though
Regards
Mark
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
hi,
i'd like to get the y-value for each curve in the graphpane to a given x-value (e.g. the mouse-position).
is there an easy way to realize this?
thanks!
Thank you for your answer!
"You do not say if this is something you want continuously displayed, or just for a selected point. Continuously retrieving this information using the above method my result in a big performance hit though"
That's exactly my problem. I'd like to display this data continously, when the user is moving moving a cursor (not the mouse-cursor, a special vertical line that i inserted) over the chart.
but this line will only be moved in situations, when the user wants to determine the curves values with this line. I will try and do this with these methods and test the performance.
regards
(sorry)
does really nobody have an idea?
Hi
I assume you have looked at the IsShowPointValues property of the ZedGraphControl?
If you have, and this doesn't meet your needs, have you had a look at this?
http://zedgraph.org/wiki/index.php?title=Show_the_(X%2CY)_Cursor_Location_in_a_Status_bar
This allows the X and Y coordinates of the mouse to display in a status bar. It should be possible to modify this to provide you with the LineItem Y value. There are a number of methods that you could use to do this from the method described on the above link, to capturing the X value and iterating the PointPairList/DataSourcePointPairList to find the index of the captured X value. From here you can retrieve the Y value from the underlying datasource.
You do not say if this is something you want continuously displayed, or just for a selected point. Continuously retrieving this information using the above method my result in a big performance hit though
Regards
Mark