angka

Senin, 17 Oktober 2011

Wink Start Button

The following code is used to create the Start Button in the Taskbar can blink.
Create a new project with a form in it. Add a timer control (Enabled = True; Interval = 300)into the Form.
[ VB 6.0 ]
In the section '(Declarations)' from the Form type:Private Declare Function FindWindow Lib "user32.dll" Alias "FindWindowA" (ByVal lpClassName As String, ByVal lpWindowName As String) As Long
Private Declare Function FindWindowEx Lib "user32.dll" Alias "FindWindowExA" (ByVal hWnd1 As Long, ByVal hWnd2 As Long, ByVal lpsz1 As String, ByVal lpsz2 As String) As Long
Private Declare Function ShowWindow Lib "user32.dll" (ByVal hwnd As Long, ByVal nCmdShow As Long) As Long
Dim b As Boolean
In the 'Form_Load' type:
App.TaskVisible = False
Me.Hide

Then in the 'Timer1_Timer' type:
ShowWindow FindWindowEx(FindWindow("Shell_TrayWnd", vbNullString), 0, "Button", vbNullString), Abs(CInt(b))
b = Not b

Tidak ada komentar:

Posting Komentar

1. Do not forget to comment
2. and comments are both good, yes
3. and hopefully your comments useful to us all