Measurement Studio for VB6

cancel
Showing results for 
Search instead for 
Did you mean: 

Selecting Data in CWgraph by drawing a Rectangle

I need to Chart data using the CWgraph Active X and allow the user the capabilty to draw a selection box/rectangle on it. I would need to retrieve the starting,ending X axis and the same would be needed for the y axis.

The Feature is similar to ZoomRectXY without the Zooming. How can I achieve this. Can you please provide guidelines or examples of this.
0 Kudos
Message 1 of 2
(6,243 Views)
The standard way to provide this functionality is through cursors. You would create two cursors, which your users would position to create the selection box.

Is this solution satisfactory for you?

If not, it is possible to do exactly what you are asking, but it will require a bit more implementation on your part. Basically, you use the PlotAreaMouse events to determine when and where the user clicks, drags, and releases. You will have to draw the selection rectangle yourself. Look at this post to see an example of this being done in the 3D graph. You should be able to use it as a basis for implementation of the same functionality for CWGraph.
0 Kudos
Message 2 of 2
(6,243 Views)