private void timer1_Tick(object sender, EventArgs e)
{
//学习进度条控件
this.progressBar1.Minimum = 0;//进度条最小值
this.progressBar1.Maximum = 10000;//最大值
this.progressBar1.Step = 1;//步进值
//调用for循环动态显示进度条的当前进度值
for (int i = 0; i < 10000; i++)
{
//performstep以设置的step步进值递增进度条当前进度
this.progressBar1.PerformStep();
//在文本框中显示当前进度
this.currpos.Text = this.progressBar1.Value.ToString();
}
}
{
//学习进度条控件
this.progressBar1.Minimum = 0;//进度条最小值
this.progressBar1.Maximum = 10000;//最大值
this.progressBar1.Step = 1;//步进值
//调用for循环动态显示进度条的当前进度值
for (int i = 0; i < 10000; i++)
{
//performstep以设置的step步进值递增进度条当前进度
this.progressBar1.PerformStep();
//在文本框中显示当前进度
this.currpos.Text = this.progressBar1.Value.ToString();
}
}
来自 “ ITPUB博客 ” ,链接:http://blog.itpub.net/9240380/viewspace-717118/,如需转载,请注明出处,否则将追究法律责任。
转载于:http://blog.itpub.net/9240380/viewspace-717118/