Sorry, today I posted this same question with the title How to clear a draw on a plane, instead of How to clear a drawing on a panel
I capture several points (coordinates) of my position and draw a polygon on a panel using the DrawLine method, but sometimes I need to erase the drawing to repeat the process.
The only way I've found to do this is to use panel1.RemoveView, but when I redraw the lines of the new polygon, the lines don't display.
It seems the RemoveView method is too powerful for this case and delete more things that the drawing.
1. Should I use another method?
2. How can I reactivate the DrawLine method?
I capture several points (coordinates) of my position and draw a polygon on a panel using the DrawLine method, but sometimes I need to erase the drawing to repeat the process.
The only way I've found to do this is to use panel1.RemoveView, but when I redraw the lines of the new polygon, the lines don't display.
It seems the RemoveView method is too powerful for this case and delete more things that the drawing.
1. Should I use another method?
2. How can I reactivate the DrawLine method?