Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
可能重复: 如何修复用户控件中的闪烁
我的文本框在更新文本时闪烁。 我用每 100 毫秒计时一次的计时器更新我的文本框。(将其视为日志窗口)。
问题 如何防止这种闪烁?
谢谢!
我认为你应该:
a) 减慢计时器的滴答速度
b) 启用双缓冲
c) 将Application.DoEvents( ) 放在将文本添加到 TextBox 的行之后
不过,这更像是一种解决方法。我只是降低滴答声。