Quote:
Originally posted by jezoo
I am using the OnMouseDown and OnMouseUp events in MS VC .Net, VB .Net, VC# to draw things like lines or rectangles etc. Every time I draw something, if I switch to another application, when I come back to the form, it looses the graphics on it. I have never seen such a thing and God knows I have used C++ Builder, Delphi, MS Visual C++ 6 and MS Visual Basic 6. This happens only on MS .Net when the form looses focus. I know it works fine if I use the OnPaint event but that's not where I want to perform drawing. I have tried different operting systems (WinXP and Win2000). Does anybody know what I can do to keep the drawings on the form?
yup.. i've got the same thing... what i did is just made class members to register what i wanna draw in and then call RedrawWindow (i'm pretty sure that was the name of the function) on