Membuat Form Bergerak Ketika Diklik Visual Basic 6.0


Langkah-langkah:

1. siapkan project baru,

2. masukkan kode berikut:

 

Private Sub Form_Click()
Me.Left = Me.Left + 500
If  Me.Left = 10000 Then Me.Left = 0
End Sub

Private Sub Form_Load()
Me.Left = 0
End Sub

 

3. coba tekan f5 dan klik formnya..

me.left menunjukkan posisi sebelah kiri form..

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s