希望有人帮忙把这个VB程序转化为C++程序,谢谢。
希望有人帮忙把这个VB程序转化为C++程序,谢谢。Public Enum enuFlashOptions
FLASHW_ALL = &H3 ' Flash both the window caption and taskbar button.
' This is equivalent to setting the FLASHW_CAPTION | FLASHW_TRAY flags.
FLASHW_CAPTION = &H1 ' Flash the window caption.
FLASHW_STOP = 0 ' Stop flashing. The system restores the window to its original state.
FLASHW_TIMER = &H4 ' Flash continuously, until the FLASHW_STOP flag is set.
FLASHW_TIMERNOFG = &HC ' Flash continuously until the window comes to the foreground.
FLASHW_tray = &H2
End Enum
Public Type FlashWindowInfo
cbSize As Long
hWnd As Long
dwflags As Long
uCount As Long
dwTimeout As Long
End Type
Private Declare Function FlashWindowEx Lib "user32.dll" (ByRef pInfo As FlashWindowInfo) As Boolean
Public Sub FlashWindow(ByVal hWnd As Long, ByVal FlashWindowInfoFlags As enuFlashOptions, Optional ByVal intFlashTimes As Long = 2)
Dim info As FlashWindowInfo
With info
.cbSize = Len(info)
.dwflags = FlashWindowInfoFlags ' See enumeration for flag values
.dwTimeout = 0 'Flash rate in ms or default cursor blink rate
.hWnd = hWnd
.uCount = intFlashTimes ' Number of times to flash
End With
FlashWindowEx info
End Sub
Sub flash(hWnd)
FlashWindow hWnd, FLASHW_TIMERNOFG Or FLASHW_tray, 0
End Sub