(i)Have an internal representaion of the data to be plotted
(ex. an array of X,Y values)
Then in the Form_resize event write code to plot the graph from this data.
(ii) For Zooming, its a bit involved:
Write code to draw rectangle. (use the mouse click, move events)
Then trap the mouse move to position the rectangle
Then on Mouse-Up figure out the area covered by the rectangle
Map this with your internal representation.
Redraw the graph
Got it?
Quote:
> Hi,
> I am trying to implements a ploting function in my project. I am trying
to
> use used the picture as my canvas to plot the graph on. What I am trying
to
> do is that I want to plot the graph which is resizeable and also when the
> user double click or just one left click it be able to zoom into the
region
> where the user click on.
> I wonder is there any example where I can have a look on how to do this.
> The reason that I am using the picture box because I have one text box
> below the picture box to display the details of the wave form and other
> stuff. Or is there any free code where I can download and have a look at
> how it is implemented??
> --
> Keat Jau
> Final year Computer Engineering student at
> University of Newcastle