以文本方式查看主题

-  Foxtable(狐表)  (http://foxtable.com/bbs/index.asp)
--  专家坐堂  (http://foxtable.com/bbs/list.asp?boardid=2)
----  [求助]窗口PANLE添加的图片闪动  (http://foxtable.com/bbs/dispbbs.asp?boardid=2&id=124657)

--  作者:blsu33
--  发布时间:2018/9/11 14:47:00
--  [求助]窗口PANLE添加的图片闪动
老师,
窗口PANLE添加的图片闪动加载后闪动的厉害,怎么能改善下,StopRedraw()
 不管用
--  作者:有点甜
--  发布时间:2018/9/11 14:48:00
--  

双缓存

 

http://www.foxtable.com/bbs/dispbbs.asp?BoardID=2&ID=83950

 


--  作者:blsu33
--  发布时间:2018/9/11 15:05:00
--  
老师,
  直接 写 这句?
e.Form.panel.Gettype().GetProperty("DoubleBuffered",  Reflection.BindingFlags.Instance Or System.Reflection.BindingFlags.NonPublic).SetValue( e.Form.panel,True,Nothing)

不改成我自己的PANL吗,例如

e.Form.panel.Gettype().GetProperty("DoubleBuffered",  Reflection.BindingFlags.Instance Or System.Reflection.BindingFlags.NonPublic).SetValue( e.Form.panel,True,Nothing)

--  作者:有点甜
--  发布时间:2018/9/11 15:09:00
--  

比如

 

Dim p As WinForm.Panel = e.Form.Controls("panel1")
p.baseControl.Gettype().GetProperty("DoubleBuffered",  Reflection.BindingFlags.Instance Or System.Reflection.BindingFlags.NonPublic).SetValue(p.baseControl,True,Nothing)

[此贴子已经被作者于2018/9/11 15:09:25编辑过]

--  作者:blsu33
--  发布时间:2018/9/11 15:11:00
--  
好了