R
Rick Jones
I think I have a big job ahead of me but before I invest too much time I'm
wondering if it can be done at all. I would like to have an x-y graph where
I have plotted the outside contour of some object (for discussion purposes
it is the side view of a rocket ship). I would like to have a vertical line
in this plot that can be moved left or right within the plot area (but not
allowed to go out of this area) using the cursor (left mouse button) such
that when I release the button, the x position of the vertical line is
linked to a cell in the worksheet. This x value would also be shown
adjacent to the line as the line is moved. This x value is then used in a
lookup table to get data to graph (in a second graph) the diameter of the
rocket ship at that x position. The part that I don't know how to do is
what type of line do I use, how to move this line around, make sure the line
cannot be dragged out of the plot area (assumes the line is a drawn object
and not a second data series), and how to get the x position (as well as
link it to the cell) when I release the mouse button. It would be nice if
the mouse button were to change shape to a double headed, horizontal arrow
when it was over the vertical line (and the line could only be moved when
the cursur was this horizontal arrow).
I have been somewhat successful in accomplishing the above goal but using a
less eloquent solution. To obtain the vertical line, I plotted a second
series (2 pts having the same x value and y values that were low and high
enough that the connecting line spanned the plot area). I utilized a
horizontal scroll bar linked to a cell to change the x value of the second
series. Moving the scroll bar moves the vertical line real time but the
plot flashes like crazy - extremely annoying. It works ... but for this
engineering application I would much rather move the line with the cursor
and not have have the graph flashing at the user.
Thanks,
Rick
wondering if it can be done at all. I would like to have an x-y graph where
I have plotted the outside contour of some object (for discussion purposes
it is the side view of a rocket ship). I would like to have a vertical line
in this plot that can be moved left or right within the plot area (but not
allowed to go out of this area) using the cursor (left mouse button) such
that when I release the button, the x position of the vertical line is
linked to a cell in the worksheet. This x value would also be shown
adjacent to the line as the line is moved. This x value is then used in a
lookup table to get data to graph (in a second graph) the diameter of the
rocket ship at that x position. The part that I don't know how to do is
what type of line do I use, how to move this line around, make sure the line
cannot be dragged out of the plot area (assumes the line is a drawn object
and not a second data series), and how to get the x position (as well as
link it to the cell) when I release the mouse button. It would be nice if
the mouse button were to change shape to a double headed, horizontal arrow
when it was over the vertical line (and the line could only be moved when
the cursur was this horizontal arrow).
I have been somewhat successful in accomplishing the above goal but using a
less eloquent solution. To obtain the vertical line, I plotted a second
series (2 pts having the same x value and y values that were low and high
enough that the connecting line spanned the plot area). I utilized a
horizontal scroll bar linked to a cell to change the x value of the second
series. Moving the scroll bar moves the vertical line real time but the
plot flashes like crazy - extremely annoying. It works ... but for this
engineering application I would much rather move the line with the cursor
and not have have the graph flashing at the user.
Thanks,
Rick