|
-
Nov 19th, 2003, 12:35 PM
#7
Originally posted by Edneeis
Well that is what the MouseHover event does, but if you want more control over the time it takes or really want to use the Timer then:
VB Code:
Private WithEvents _Timer As New Timer
Private Sub PictureBox1_MouseLeave(ByVal sender As Object, ByVal e As System.EventArgs) Handles PictureBox1.MouseLeave
'although unless the button is in the picturebox they wont eb able to click it
'since it will disappear when they leave the picturebox to click it
Button1.Visible = False
_Timer.Enabled = False
End Sub
Private Sub PictureBox1_MouseEnter(ByVal sender As Object, ByVal e As System.EventArgs) Handles PictureBox1.MouseEnter
_Timer.Interval = 2000
_Timer.Enabled = True
End Sub
Private Sub _Timer_Tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles _Timer.Tick
Button1.Visible = True
End Sub
There is more than one Timer object so check which one you are using. I am using the one from the Windows.Forms namespace not the Threading namespace one.
hmm that one works? I was using teh one from System.Timers
rate my posts if they help ya!
Extract thumbnail without reading the whole image file: (C# - VB)
Apply texture to bitmaps: (C# - VB)
Extended console library: (VB)
Save JPEG with a certain quality (image compression): (C# - VB )
VB.NET to C# conversion tips!!
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|