[TUTORIAL] : Make a fading exit effect on your form
This is my little tutorial about making a fading exit-effect on a form
CONTROLS - Add the following to your form
- 1 Timer (Enabled=False, Interval=1)
STEP-BY-STEP - The How To
- Declare the following variables before any functions/subs yet within the class
- Add this to your form's load codeCode:Dim cancelClose As Boolean = True
- Add this to your timers "tick" codeCode:Me.AllowTransparency = True
- Finally, add this to the form's FormClosing() eventCode:Me.Opacity -= 0.05 If Me.Opacity = 0 Then cancelClose = False Me.Close() End If
YOUR DONE!Code:fadetimer.Enabled = True e.Cancel = cancelClose
Enjoy your fading form![]()




Reply With Quote