Senin, 14 April 2014
Browse »
home»
menampilkan
»
screensaver
»
trik
»
vb
»
Trik VB Menampilkan ScreenSaver
Trik VB Menampilkan ScreenSaver
Trik VB Menampilkan ScreenSaver - ScreenSaver ternyata bisa juga dipakai lewat VB loh. Untuk menampilkan screensaver lewat VB, caranya sangat mudah kok. Kalian cuma butuh 1 project dan 1 form saja.
Di bagian (Declarations) dari Form ketikkan :
Option Explicit
Private Declare Function SendMessage Lib "user32" Alias "SendMessageA" (ByVal hwnd As Long, ByVal wMsg As Long, ByVal wParam As Long, ByVal lParam As Any) As Long
Const SC_SCREENSAVE = &HF140&
Const MON_OFF = 2&
Const WM_SYSCOMMAND = &H112
Di bagian Form_Load ketikkan :
Private Sub Form_Load()
SendMessage Me.hwnd, WM_SYSCOMMAND, SC_SCREENSAVE, Monochrome
End Sub
Selamat Mencoba :D
Langganan:
Posting Komentar (Atom)
Tidak ada komentar:
Posting Komentar