Resizing Form using Timer vb 2005
IDE : VS 2005, VS 2008,
Platform : .NET 2.0, .NET 3.0, .NET 3.5,
Hello everybody !
Today i wanted to resize Form using Timer. I have created new Timer, i have also set the interval which is 100 ms, and everything was okay, so i was expecting, that if i set the interval to 50 ms - then my Form will resize faster. Sadly - i cant get it resize faster, dunno why. There's a code im using below :
Code:
Public x as Integer = 192
Me.TimerForm.Start()
Me.TimerForm.Interval = 20
'here Timer code :
Private Sub TimerForm_Tick(ByVal myObject As System.Object, ByVal e As System.EventArgs)
If x > 329 Then TimerForm.Stop()
x = x + 1
Me.Size = New Size(484, x)
End Sub
Anyone can help ?
Regards,
Pete
I'll put the whole code as it is :
Code:
Public Class BeginLogin
Public x as Integer = 192
Dim TimerForm As New Timer
Private Sub DoLoginToolStripMenuItem_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles DoLoginToolStripMenuItem.Click
AddHandler TimerForm.Tick, AddressOf TimerForm_Tick
Me.TimerForm.Start()
Me.TimerForm.Interval = 100
End Sub
Private Sub TimerForm_Tick(ByVal myObject As System.Object, ByVal e As System.EventArgs)
If x > 329 Then TimerForm.Stop()
x = x + 1
Me.Size = New Size(484, x)
End Sub
End Class
Now - no matter what if i set interval to 20 or 10, the form is not resizing faster (yes maybe a little bit yes), but id like to resize it rly fast.
source :http://www.vbcity.com
-------------------------------------------------------
Trik Gambar Bergerak
Trik Gambar-dimouse
Trik hapus pwd mysql
Trik insertin to db
Trik jadi root dilinux
Trik jam-distatus-bar
Trik Koneksi-ke database
Trik Koneksi-msql-php
Trik lihat-database-mysql
Trik membahas-fungsi-else
Trik member-area
Rabu, 04 Februari 2009
Langganan:
Postingan (Atom)