stuff i do at work

(maybe i’ll make less mistakes if i remember some)

Dumb mistake of the day: why is the form rendering 7 times?

Posted by noah on October 2, 2008

This one was odd.  I noticed that OnPaint was called 7 times per normal refresh, and only after an unrelated exception occurred somewhere else (WCF connection faulted).  This happened because I was switching ForeColor of the control, and the control refreshed each time it was changed.  Don’t know why it only happened after disconnect, though.

Leave a Reply

XHTML: You can use these tags: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <pre> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>