Have your form change colors nicely without flickering:
VB Code:
  1. Option Explicit
  2. Dim r As Byte, g As Byte, b As Byte, flag As Byte, d(3) As Byte
  3.  
  4. Private Sub Form_Load()
  5.     r = 255: g = 255: b = 255: flag = 0
  6. End Sub
  7.  
  8. Function Disco()
  9.  
  10.     If flag Then
  11.         r = DoIt(1, r)
  12.         g = DoIt(2, g)
  13.         b = DoIt(3, b)
  14.         flag = flag - 1
  15.     Else
  16.         r = Ran(1, r)
  17.         g = Ran(2, g)
  18.         b = Ran(3, b)
  19.         flag = 50
  20.     End If
  21.         Me.BackColor = RGB(r, g, b)
  22.  
  23. End Function
  24.  
  25. Function DoIt(ByVal a As Byte, ByVal c As Byte)
  26.     If ((d(a) = 2 And c < 255) Or c = 0) Then
  27.         c = c + 1
  28.         d(a) = 2
  29.     Else
  30.         If ((d(a) = 1 And c) Or c = 255) Then
  31.             c = c - 1
  32.             d(a) = 1
  33.         End If
  34.                 If a = 3 Then
  35.             If (d(1) + d(2) + d(3) = 0) Then flag = 1
  36.         End If
  37.     End If
  38.  
  39.     DoIt = c
  40.  
  41. End Function
  42.  
  43. Private Sub Timer1_Timer()
  44. Disco
  45. End Sub
  46.  
  47. Function Ran(ByVal a As Byte, ByVal c As Byte)
  48.    
  49.     If ((Rnd > 0.667 Or c = 0) And c < 255) Then
  50.         c = c + 1
  51.         d(a) = 2
  52.     ElseIf ((Rnd <= 0.5 Or c = 255) And c > 0) Then
  53.         c = c - 1
  54.         d(a) = 1
  55.     Else
  56.         d(a) = 0
  57.     End If
  58.  
  59.     Ran = c
  60.    
  61. End Function

To Make a form Opacity fade:
VB Code:
  1. Dim cat as string
  2.  
  3. Private Sub Timer2_Timer()
  4.   Select Case cat
  5.     Case "Up"
  6.       x = Val(x) + 1
  7.       If Val(x) >= 255 Then cat = "Down"
  8.     Case "Down"
  9.       x = Val(x) - 1
  10.       If Val(x) <= 150 Then cat = "Up"
  11.     Case ""
  12.       cat = "Up"
  13.   End Select
  14.   Call Mache_Transparent(Me.hWnd, 0)
  15. End Sub
  16.  
  17. Private Sub Form_Load()
  18.     x = 120
  19. cat = "Up"
  20. End Sub
  21. '------------------------------------------------------
  22. 'Add below to a module
  23.  
  24. Option Explicit
  25.  
  26. Declare Function GetWindowLong Lib "user32.dll" Alias _
  27. "GetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long) As Long
  28. Declare Function SetWindowLong Lib "user32.dll" Alias _
  29. "SetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long, ByVal _
  30.         dwNewLong As Long) As Long
  31. Declare Function SetLayeredWindowAttributes Lib "user32.dll" (ByVal _
  32. hWnd As Long, ByVal crKey As Long, ByVal bAlpha As Byte, ByVal _
  33.         dwFlags As Long) As Long
  34.  
  35. Public Const GWL_EXSTYLE = (-20)
  36. Public Const WS_EX_LAYERED = &H80000
  37.  
  38. Public Const LWA_ALPHA = &H2
  39. Public x As Integer
  40.  
  41. Public Sub Mache_Transparent(hWnd As Long, Rate As Byte)
  42.     Dim Opacity As Integer
  43.     Opacity = x
  44.     Rate = Opacity
  45.     Dim WinInfo As Long
  46.    
  47.     WinInfo = GetWindowLong(hWnd, GWL_EXSTYLE)
  48.    
  49.     If Rate < 255 Then
  50.         WinInfo = WinInfo Or WS_EX_LAYERED
  51.         SetWindowLong hWnd, GWL_EXSTYLE, WinInfo
  52.         SetLayeredWindowAttributes hWnd, 0, Rate, LWA_ALPHA
  53.     Else
  54.         WinInfo = WinInfo Xor WS_EX_LAYERED
  55.         SetWindowLong hWnd, GWL_EXSTYLE, WinInfo
  56.     End If
  57. End Sub

To make a form Opacity fade and Color Fade:

VB Code:
  1. Option Explicit
  2.  
  3. Dim r As Byte, g As Byte, b As Byte, flag As Byte, d(3) As Byte, cat As String
  4.  
  5. Private Sub Form_Load()
  6.     r = 255: g = 255: b = 255: flag = 0
  7.     x = 120: cat = "Up"
  8. End Sub
  9.  
  10. Function Disco()
  11.  
  12.     If flag Then
  13.         r = DoIt(1, r)
  14.         g = DoIt(2, g)
  15.         b = DoIt(3, b)
  16.         flag = flag - 1
  17.     Else
  18.         r = Ran(1, r)
  19.         g = Ran(2, g)
  20.         b = Ran(3, b)
  21.         flag = 50
  22.     End If
  23.         Me.BackColor = RGB(r, g, b)
  24.  
  25. End Function
  26.  
  27. Function DoIt(ByVal a As Byte, ByVal c As Byte)
  28.     If ((d(a) = 2 And c < 255) Or c = 0) Then
  29.         c = c + 1
  30.         d(a) = 2
  31.     Else
  32.         If ((d(a) = 1 And c) Or c = 255) Then
  33.             c = c - 1
  34.             d(a) = 1
  35.         End If
  36.                 If a = 3 Then
  37.             If (d(1) + d(2) + d(3) = 0) Then flag = 1
  38.         End If
  39.     End If
  40.  
  41.     DoIt = c
  42.  
  43. End Function
  44.  
  45. Function Ran(ByVal a As Byte, ByVal c As Byte)
  46.    
  47.     If ((Rnd > 0.667 Or c = 0) And c < 255) Then
  48.         c = c + 1
  49.         d(a) = 2
  50.     ElseIf ((Rnd <= 0.5 Or c = 255) And c > 0) Then
  51.         c = c - 1
  52.         d(a) = 1
  53.     Else
  54.         d(a) = 0
  55.     End If
  56.  
  57.     Ran = c
  58.    
  59. End Function
  60.  
  61. Private Sub Timer2_Timer()
  62. Disco
  63.   Select Case cat
  64.     Case "Up"
  65.       x = Val(x) + 1
  66.       If Val(x) >= 255 Then cat = "Down"
  67.     Case "Down"
  68.       x = Val(x) - 1
  69.       If Val(x) <= 150 Then cat = "Up"
  70.     Case ""
  71.       cat = "Up"
  72.   End Select
  73.   Call Mache_Transparent(Me.hWnd, 0)
  74. End Sub
  75.  
  76. Public Sub Mache_Transparent(hWnd As Long, Rate As Byte)
  77.     Dim Opacity As Integer
  78.     Opacity = x
  79.     Rate = Opacity
  80.     Dim WinInfo As Long
  81.    
  82.     WinInfo = GetWindowLong(hWnd, GWL_EXSTYLE)
  83.    
  84.     If Rate < 255 Then
  85.         WinInfo = WinInfo Or WS_EX_LAYERED
  86.         SetWindowLong hWnd, GWL_EXSTYLE, WinInfo
  87.         SetLayeredWindowAttributes hWnd, 0, Rate, LWA_ALPHA
  88.     Else
  89.         WinInfo = WinInfo Xor WS_EX_LAYERED
  90.         SetWindowLong hWnd, GWL_EXSTYLE, WinInfo
  91.     End If
  92. End Sub
  93. '-----------------------------------------------------
  94. 'Below in module
  95. Declare Function GetWindowLong Lib "user32.dll" Alias _
  96. "GetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long) As Long
  97. Declare Function SetWindowLong Lib "user32.dll" Alias _
  98. "SetWindowLongA" (ByVal hWnd As Long, ByVal nIndex As Long, ByVal _
  99.         dwNewLong As Long) As Long
  100. Declare Function SetLayeredWindowAttributes Lib "user32.dll" (ByVal _
  101. hWnd As Long, ByVal crKey As Long, ByVal bAlpha As Byte, ByVal _
  102.         dwFlags As Long) As Long
  103.  
  104. Public Const GWL_EXSTYLE = (-20)
  105. Public Const WS_EX_LAYERED = &H80000
  106.  
  107. Public Const LWA_ALPHA = &H2
  108. Public x As Integer

To make a form Draggable by clicking:
VB Code:
  1. Private Declare Function ReleaseCapture Lib "user32" () As Long
  2.  Private Declare Function SendMessage Lib "user32" _
  3.  Alias "SendMessageA" (ByVal hWnd As Long, ByVal wMsg As Long, _
  4.  ByVal wParam As Long, lParam As Any) As Long
  5.  
  6. Sub MoveObject(Obj As Object)
  7.   Const WM_NCLBUTTONDOWN = &HA1
  8.   Const HTCAPTION = 2
  9.  
  10.   ReleaseCapture
  11.   SendMessage Obj.hWnd, WM_NCLBUTTONDOWN, HTCAPTION, 0
  12. End Sub
  13.  
  14. Private Sub Label1_MouseDown(Button As Integer, Shift As Integer, x As Single, y As Single)
  15.   If Button = vbLeftButton Then
  16.     MoveObject Me
  17.   End If
  18. End Sub

How to fade a forms MENU bar:
VB Code:
  1. Option Explicit
  2. Dim r As Byte, g As Byte, b As Byte, flag As Byte, d(3) As Byte, cat As String
  3. Private Const MIM_BACKGROUND As Long = &H2
  4. Private Const MIM_APPLYTOSUBMENUS As Long = &H80000000
  5.  
  6. Private Type MENUINFO
  7.     cbSize As Long
  8.     fMask As Long
  9.     dwStyle As Long
  10.     cyMax As Long
  11.     hbrBack As Long
  12.     dwContextHelpID As Long
  13.     dwMenuData As Long
  14. End Type
  15.  
  16. Private Declare Function DrawMenuBar Lib "user32" _
  17.     (ByVal hWnd As Long) As Long
  18.  
  19. Private Declare Function GetSubMenu Lib "user32" _
  20.     (ByVal hMenu As Long, ByVal nPos As Long) As Long
  21.  
  22. Private Declare Function GetMenu Lib "user32" _
  23.     (ByVal hWnd As Long) As Long
  24.  
  25. Private Declare Function SetMenuInfo Lib "user32" _
  26.     (ByVal hMenu As Long, _
  27.      mi As MENUINFO) As Long
  28.  
  29. Private Declare Function CreateSolidBrush Lib "gdi32" _
  30.     (ByVal crColor As Long) As Long
  31.  
  32.  
  33. Private Sub Form_Load()
  34. r = 255: g = 255: b = 255: flag = 0
  35. End Sub
  36.  
  37. Function Disco()
  38.  
  39.     If flag Then
  40.         r = DoIt(1, r)
  41.         g = DoIt(2, g)
  42.         b = DoIt(3, b)
  43.         flag = flag - 1
  44.     Else
  45.         r = Ran(1, r)
  46.         g = Ran(2, g)
  47.         b = Ran(3, b)
  48.         flag = 50
  49.     End If
  50.  
  51. End Function
  52.  
  53.  
  54. Function DoIt(ByVal a As Byte, ByVal c As Byte)
  55.     If ((d(a) = 2 And c < 255) Or c = 0) Then
  56.         c = c + 1
  57.         d(a) = 2
  58.     Else
  59.         If ((d(a) = 1 And c) Or c = 255) Then
  60.             c = c - 1
  61.             d(a) = 1
  62.         End If
  63.                 If a = 3 Then
  64.             If (d(1) + d(2) + d(3) = 0) Then flag = 1
  65.         End If
  66.     End If
  67.  
  68.     DoIt = c
  69.  
  70. End Function
  71.  
  72. Function Ran(ByVal a As Byte, ByVal c As Byte)
  73.    
  74.     If ((Rnd > 0.667 Or c = 0) And c < 255) Then
  75.         c = c + 1
  76.         d(a) = 2
  77.     ElseIf ((Rnd <= 0.5 Or c = 255) And c > 0) Then
  78.         c = c - 1
  79.         d(a) = 1
  80.     Else
  81.         d(a) = 0
  82.     End If
  83.  
  84.     Ran = c
  85.    
  86. End Function
  87.  
  88. Private Sub Timer1_Timer()
  89. Disco
  90. Dim mi As MENUINFO
  91.    
  92.     With mi
  93.         .cbSize = Len(mi)
  94.        
  95.         .fMask = MIM_BACKGROUND
  96.         .hbrBack = CreateSolidBrush(RGB(r, g, b))
  97.         SetMenuInfo GetMenu(Me.hWnd), mi  'main menu bar
  98.                 .fMask = MIM_BACKGROUND Or MIM_APPLYTOSUBMENUS
  99.         .hbrBack = CreateSolidBrush(RGB(r, g, b))
  100.         SetMenuInfo GetSubMenu(GetMenu(Me.hWnd), 0), mi 'File menu (item 0)
  101.                 .hbrBack = CreateSolidBrush(RGB(r, g, b))
  102.         SetMenuInfo GetSubMenu(GetMenu(Me.hWnd), 1), mi 'Edit menu (item 1)
  103.                 .hbrBack = CreateSolidBrush(RGB(r, g, b))
  104.         SetMenuInfo GetSubMenu(GetMenu(Me.hWnd), 2), mi 'Select menu (item 2)
  105.             End With
  106.         DrawMenuBar Me.hWnd
  107. End Sub

Hope you all liked it..If so ill try and figure out some cool new ones. Enjoy!