使用tablelayoutpanel当容器,里面放了一堆控件,每次一次性要刷新40多个LABEL,这时界面闪烁的非常厉害,我更改LABEL的TEXT前时候了使用了一个什么 s什么什么layout方法,在全部刷新完后再使用resumelayout方法,好象不太好用,请问还有什么方法能是他刷新时不会闪烁?????

解决方案 »

  1.   

    It wouldn't surprise me that you get flicker with this number of controls. either:1. Reduce the number of controls , this is more than likely not an option...2. perform your own 'drawing' onto the form (or usercontrol) itself (and use doublebuffering to improve the graphical smothness).You may be able to use SuspendLayout() and ResumeLayout() (not sure if it'll improve things or not).3. Set it's visibility to false before you update if, then set it back after you finish(still not sure whether it will help)What is happening is that when you update each label, it is clearing itself by 'filling' in the background color, then displaying the value you want. The more controls you have, the more noticable this effect.