Kamis, 21 Juni 2012

PERANCANGAN DISPLAY INTERFACE VB

 Membuat Tampilan Menu dengan Aquarium

 Goto Page
Tampilan Menu dengan Effect Kaca

Menu Berkerja dengan Facedetection


goto Preview:
http://www.ziddu.com/download/19726069/MenudikendalikanFacedetection.wmv.html

Menu Effect Glees ( Menu effek Kaca)

Buat rancangan Form Seperti Gambar di Bawah ini
Komponen yang digunakan :

1. Form   Seting : Windowsate = 2-Maximized
2. Picture Box
     => Picture1  : Setting Name = Pic1, Autoredraw = True
    => Picture 2  : Setting Name = Pic2, Autoredraw = True, Apearance = 0-Flat
3. Timer 2 buat : Setting Enabld = False, Interval = 50
4. RudyBotton :


Code Program:


Code Prigram :

Dim i As Boolean
Dim Px, Py As Integer
Dim postengah, PosReight As Integer

Private Sub BotBack_Click()
Timer2.Enabled = True
End Sub

Private Sub CmdNext_Click()
Timer1.Enabled = True
CmdNext.Visible = False
RudieButton1.Visible = True
End Sub

Private Sub Form_Load()
postengah = (Screen.Width - pic2.Width) / 2
PosReight = (Screen.Width / 2)
Me.Caption = PosReight
i = True
Pic1.Top = 0 ‘ Mengatus Posisi Atas Awal
Pic1.Left = 0 ‘Mengatur Posisi Kiri Wal
End Sub

Private Sub pic2_MouseDown(Button As Integer, Shift As Integer, X As Single, Y As Single)
Px = X
Py = Y
End Sub

Private Sub pic2_MouseMove(Button As Integer, Shift As Integer, X As Single, Y As Single)
If Button = 1 Then ‘ Mose Click Kiri
pic2.Top = pic2.Top - (Py - Y)
pic2.Left = pic2.Left - (Px - X)
End If
 pic2.PaintPicture Pic1, 0, 0, pic2.Width * 1.5, pic2.Height * 1.5, pic2.Left + 10, pic2.Top + 10, pic2.Width, pic2.Height
End Sub

Private Sub Timer1_Timer() ‘Menu Open
If pic2.Height < 4860 Then ‘ Mengatur tinggi Picture Box
pic2.Height = pic2.Height + (pic2.Height / 2)
End If
If pic2.Width < 7740 Then ‘Mengatur Lebar Picture Box
pic2.Width = pic2.Width + (pic2.Width / 2)
End If
If pic2.Top < (Screen.Height - pic2.Height) / 2 Then ‘ Mengatur posisi Atas Picture Box
pic2.Top = pic2.Top + (pic2.Top / 2)
End If
If pic2.Left > 9200 Then ‘Mengatur posisi kiri Picture Box
Timer1.Enabled = False ‘ Proses Pergerakan di hentikan
Else
pic2.Left = pic2.Left + (pic2.Left / 2)
End If
pic2.PaintPicture Pic1, 0, 0, pic2.Width * 1.6, pic2.Height * 1.6, pic2.Left + 100, pic2.Top + 100, pic2.Width, pic2.Height ‘ Membuat Paint Pada picture box 2
End Sub

Private Sub Timer2_Timer() ‘ Menu Close
If pic2.Width > 1620 Then ‘ Mengatur Lebar Picture box
    pic2.Width = pic2.Width - (pic2.Width / 2)
End If
If pic2.Height > 660 Then  ‘ Mengatur  tinggi  Picture Box
pic2.Height = pic2.Height - (pic2.Height / 2)
End If
If pic2.Top > 240 Then  ‘Mengatur Posisi Atas Picture box
pic2.Top = pic2.Top - (pic2.Top / 2)
End If
If pic2.Left < 360 Then  ‘Mengatur posisi Kiri Picture Box
Timer2.Enabled = False
pic2.Width = 1620
pic2.Left = 240
pic2.Top = 360
pic2.Height = 660
CmdNext.Visible = True
RudieButton1.Visible = False
Else
pic2.Left = pic2.Left - ((pic2.Left) / 2)
End If
pic2.PaintPicture Pic1, 0, 0, pic2.Width * 1.6, pic2.Height * 1.6, pic2.Left + 100, pic2.Top + 100, pic2.Width, pic2.Height  ‘ Membuat Paint Pada picture box 2
End Sub

Hasilnya 



Download Source Code-nya:

Menu Effect Gless.rar
Source Code Menu Effect Kaca.pdf