Valhalla Legends Archive

Programming => General Programming => Visual Basic Programming => Topic started by: zeth369 on October 09, 2004, 08:58 PM

Title: Flash Form
Post by: zeth369 on October 09, 2004, 08:58 PM
How would i make a form flash?
Title: Re: Flash Form
Post by: hismajesty on October 09, 2004, 10:47 PM
You're a member at Stealthbot.net's forums, why not check the code bank? I posted this a while ago, and UserLoser commented on different OS's and such.

http://www.stealthbot.net/forum/index.php?showtopic=3168
Title: Re: Flash Form
Post by: zeth369 on October 10, 2004, 09:21 AM
thanks.. i was lookin for the code bank yesterday.. but i couldnt find it -.-
Title: Re: Flash Form
Post by: UserLoser. on October 11, 2004, 10:49 AM
Quote from: hismajesty[yL] on October 09, 2004, 10:47 PM
You're a member at Stealthbot.net's forums, why not check the code bank? I posted this a while ago, and UserLoser commented on different OS's and such.

http://www.stealthbot.net/forum/index.php?showtopic=3168

Hmm, I updated my PSDK recently, and there's no longer a check for WINVER >= 0x500, so it is BOOL bInvert and not DWORD dwFlags
Title: Re: Flash Form
Post by: Grok on October 11, 2004, 12:30 PM
Oh I have a class for FlashWindow somewhere .... *finding*.... ok it's a function...

Drop this in a bas module somewhere or wrap up in a class.


Public Type FLASHWINFO
    cbSize As Long
    hwnd As Long
    dwFlags As Long
    uCount As Long
    dwTimeout As Long
End Type

Public Declare Function FlashWindowEx Lib "user32" (lpFWI As FLASHWINFO) As Long

'-------------------------------------------------------------------
'FlashWin procedure flashes the given window a number of times at some rate.
'-------------------------------------------------------------------
Public Function FlashWin(ByVal pWnd As Long, ByVal pCount As Long, ByVal pTimeout As Long) As Long
   
    Dim pFW As FLASHWINFO
   
    pFW.cbSize = Len(pFW)
    pFW.dwFlags = FLASHW_ALL
    pFW.dwTimeout = pTimeout
    pFW.hwnd = pWnd
    pFW.uCount = pCount
    FlashWin = FlashWindowEx(pFW)
   
End Function


Title: Re: Flash Form
Post by: CrAzY on October 18, 2004, 07:22 PM
Flash?

Timer1_Timer ()

Dim a As Integer

If a = 0 Then
me.backcolor=vbwhite
a=1
else
me.backcolor=vbblack
a=0
end if

;)

Title: Re: Flash Form
Post by: Imperceptus on October 20, 2004, 04:24 PM
If your going down that road.....

Private Sub Form_Load()
Me.BackColor = vbBlack
End Sub

Private Sub Timer1_Timer()

If Me.BackColor = vbBlack Then
Me.BackColor = vbWhite
Else
Me.BackColor = vbBlack
End If
End Sub


Might be better to iif in the timer, not sure havent messed with iif to much.