首页 诗词 字典 板报 句子 名言 友答 励志 学校 网站地图
当前位置: 首页 > 教程频道 > .NET > C# >

textBox怎么实时显示

2012-01-09 
textBox如何实时显示for (int i 0 i 100000 i++){textBox1.Text + i.ToString() + \n\r}环境vs2

textBox如何实时显示
for (int i = 0; i < 100000; i++)
{
  textBox1.Text += i.ToString() + "\n\r";
}

环境vs2005 Winform程序

请问如何让textBox实时显示数据,而不是执行完整个for语句才显示textBox的值?

[解决办法]
程序中间加个Application.DoEvents,看看能不能实时显示。

热点排行