请问.NET里的ProgressBar控件怎么用?顶者有分

Bigenius 2004-08-05 10:49:54
如题!
...全文
400 10 打赏 收藏 转发到动态 举报
写回复
用AI写文章
10 条回复
切换为时间正序
请发表友善的回复…
发表回复
yanlingoffice 2010-06-26
  • 打赏
  • 举报
回复
用TextBox替代Lable,然后写入下面的代码:
TextBox1.Text = "正在处理数据";
TextBox1.Refresh(); ////这句是关键
eclipse_jhd 2005-06-30
  • 打赏
  • 举报
回复
请教!UP!
eclipse_jhd 2005-06-30
  • 打赏
  • 举报
回复
三楼 的!我按照你的方法写了,运行后为什么没有变化,就是个不动的进度条!
我代码如下:
this.progressBar1.Maximum = 100;
this.progressBar1.Minimum = 0;
this.progressBar1.Step = 25;
this.progressBar1.TabIndex = 11;
this.progressBar1.Value = 5;
FunctionClass.PopT_Compinfo_Auditprocess(DataConnect.strAccessPath);
this.progressBar1.PerformStep();
FunctionClass.PopT_Compinfo_Report01(DataConnect.strAccessPath);
this.progressBar1.PerformStep();
FunctionClass.PopT_Compinfo_Report02(DataConnect.strAccessPath);
this.progressBar1.PerformStep();
FunctionClass.PopReport_01_item1(DataConnect.strAccessPath);
this.progressBar1.PerformStep();
Bigenius 2004-08-05
  • 打赏
  • 举报
回复
我要是想用一个lable根据progressbar的进度显示不同的提示,比如“正在读入”和“读入完成”怎么办啊?
liefeng123 2004-08-05
  • 打赏
  • 举报
回复
楼上已经说了
newsea008 2004-08-05
  • 打赏
  • 举报
回复
progressBarMain.Maximum = m_AUpdateFiles.Count;
progressBarMain.Minimum = 1;
progressBarMain.Step = 1;
progressBarMain.Value = 1;

for(int i = 0; i < m_AUpdateFiles.Count; i++)
{
progressBarMain.PerformStep();
}
Maximum 根据实际情况来定。
lookydd 2004-08-05
  • 打赏
  • 举报
回复
帮你顶!

up....
jkflyfox 2004-08-05
  • 打赏
  • 举报
回复
根据progressBar的Value属性来判断,若达到最大值,则提示完成,否则正在读入
孟子E章 2004-08-05
  • 打赏
  • 举报
回复
http://blog.csdn.net/net_lover/archive/2004/04/19/6962.aspx
newsea008 2004-08-05
  • 打赏
  • 举报
回复
加入一个if语句就好。
if(i<m_AUpdateFiles)
{
this.label.text = “正在读入”;
}
else
{
this.Label.text = "读入完成";
}

110,536

社区成员

发帖
与我相关
我的任务
社区描述
.NET技术 C#
社区管理员
  • C#
  • Web++
  • by_封爱
加入社区
  • 近7日
  • 近30日
  • 至今
社区公告

让您成为最强悍的C#开发者

试试用AI创作助手写篇文章吧