自动刷新启动画面 [英] Auto refresh splash screen

查看:64
本文介绍了自动刷新启动画面的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

大家好,

我做了一个有闪屏的应用程序。这有一个代理更新一个工作正常的字符串。


我的问题是我想每2秒自动刷新一次。我试过Timer&线程,但还没有能够正确实现它[我之前使用过线程和计时器但仍然]。启动画面非常愚蠢,只有在应用程序在后台工作时显示文本。创建了splash对象,只有splashObj.Visible = true;这允许我继续当前的过程。


请帮帮忙!

Hi Guys,
I have made an application which has a splash screen. This has one of the delegates to update a string which works fine.

My issue is that I want to automatically refresh this splash every 2 secs. I have tried with Timer & thread but havent been able to implement it properly [I have used threads and timer before but still]. The splash screen is pretty dumb with only to show text while the app works in the back ground. The splash object is created and just splashObj.Visible = true; this allows me to continue with the current process.

Please help!

推荐答案

我不知道你用的版本是什么,


form.refresh在某些版本的vb中是一个选项


me.refresh

或者

textbox1.refresh
Im not sure what version your using but,

form.refresh is an option in some versions of vb

example:
me.refresh
Or
textbox1.refresh



我不知道你使用的版本是什么,


form.refresh在某些版本的vb中是一个选项


me.refresh

或者

textbox1.refresh
Im not sure what version your using but,

form.refresh is an option in some versions of vb

example:
me.refresh
Or
textbox1.refresh



对不起,我忘记了。我正在使用c# - .Net 2.我知道你可以这样做..Refresh()在大多数情况下工作正常但是如果我启动计时器和计时器滴答,如果我这样做.Refresh()那么这不起作用!

Sorry I forgot. I am using c# - .Net 2. I know you can do this.Refresh() which works fine in most cases but if I start a timer and on timer tick, if i do this.Refresh() then this doesnt work!


你必须确保刷新正确的对象。 "我"或这个或在所有情况下都可能没有引用正确的对象。


你应该使用它来强制重新控制一个控件的.Update()。它可用于我认为的所有控件。
you have to make sure you are refreshing the correct object(s). "me" or "this" might not be refering to the correct object in all cases.

And it''s .Update() that you should be using to force a redrew of a control. It''s available on all controls I believe.


这篇关于自动刷新启动画面的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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