I have something like the following in a loop (containing much activity):
Canvas1.DrawPath(Path1,Colors.Yellow,False,1).
None of the paths appear until the loop is finished. I have tried using DoEvents although this does not seem to involve an event. I don't know what I would apply "Invalidate" to in case that is what is needed.
How can I make the paths appear immediately after the DrawPath calls during each pass?
I attached Cnv (the canvas) to Activity and then passed Cnv to the code module where the drawing takes place. However, I am not able to invalidate Activity from there. I have tried attaching Cnv to a panel and even to a label and passing these along with Cnv to the code module. The only time I see ANY drawing is when I use Activity and then, only AFTER the loop is finished.
I could put all this code into the Activity module but it is large already.
Your first suggestion, to blot out the drawings, works well so I am using it. I forgot that rectangles are easily filled.
I had already tried your second suggestion but that didn't work for DrawText and it would only work for DrawPath when I had a breakpoint set between drawing and erasing with the background color; neither delays nor timers helped.