在vb.net上的标签一起闪烁 [英] blinking together in label on vb.net

查看:70
本文介绍了在vb.net上的标签一起闪烁的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有这样的代码



i have a code like this

Label30.Visible = Not Label30.Visible
Label31.Visible = Not Label31.Visible



i想要眨眼它们与同一时间一起并勾选


i want is to blink them together with the same time and tick

推荐答案

从工具箱中拖出一个计时器控件并双击它并输入以下代码:



Drag a timer control from your toolbox and double click on it and type this code :

Private Sub Timer1_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Timer1.Tick
        Label1.Visible = Not Label1.Visible
        Label2.Visible = Not Label2.Visible

    End Sub



确保你的计时器启用属性为真。

我希望这可行..: - )


Make sure that your timer Enabled property is true.
I hope this will work.. :-)


这篇关于在vb.net上的标签一起闪烁的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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