控制能见度问题 [英] control visibility problem

查看:89
本文介绍了控制能见度问题的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述


我遇到了一些问题,写了一些代码,似乎没有遵循应该的顺序。

代码(几乎是这样的):



progressbar1.Show();

progressBar1.Value = 5;

method();

progressBar1.value = 15;

method1();



进度条在两个方法运行之前都不会显示,我不明白为什么。

如果有人可以请一些建议吗?

谢谢。

Hi I've got some problem, wrote some code, which doesn't seem to follow the sequence it should.
Code is (almost like this):

progressbar1.Show();
progressBar1.Value=5;
method();
progressBar1.value=15;
method1();

progressbar doesn't show up till the both the methods are run, i don't understand why.
if anyone could please suggest something?
Thank you.

推荐答案



在winForm应用程序中,当您尝试同时更新ClientForm 上的某些更改时,您应该调用它们来更新客户区域尝试如下:
Hi,
In winForm Application when you try to update some changes on the ClientForm simultaneously then you should call these to update the Client Area try like this:
progressbar1.Show();
progressBar1.Value=5;
method();
Update();
Refresh();
progressBar1.value=15;
method1();
Update();
Refresh();


这篇关于控制能见度问题的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆