NEOLLE
03-08-2005, 01:33 AM
Hello Guys,
Im want to create a line by clicking two points on a picturebox. I would like to obtain a rubberbanding feature where a line is drawn tailing the mouse pointer after the first point is selected and until the second point is selected.
There are several lines already drawn in my picturebox. I saved the attributes of these lines via UDT.
My first move in obtaining this rubberbanding feature is I used the CLS method and loop through all the items in my UDT and draw them one by one during MouseMove event.
This works nicely, but the picture box flickers a lot while the loop is on going.
Is there a better way of obtaining a rubberband like feature without the flicker?
Is there a picture box property like a Redraw = False which eliminates flicker?
Thanks! :)
Im want to create a line by clicking two points on a picturebox. I would like to obtain a rubberbanding feature where a line is drawn tailing the mouse pointer after the first point is selected and until the second point is selected.
There are several lines already drawn in my picturebox. I saved the attributes of these lines via UDT.
My first move in obtaining this rubberbanding feature is I used the CLS method and loop through all the items in my UDT and draw them one by one during MouseMove event.
This works nicely, but the picture box flickers a lot while the loop is on going.
Is there a better way of obtaining a rubberband like feature without the flicker?
Is there a picture box property like a Redraw = False which eliminates flicker?
Thanks! :)