C# Tutorials and offshore development in India
    Tutorials   Resources   Forum   Reviews   Communities   Interview   Jobs   Projects   Training   Your Ad Here    
Silverlight Games | Mentor | Code Converter | Articles | Code Factory | Computer Jokes | Members | Peer Appraisal | IT Companies | Bookmarks | Polls | Revenue Sharing | Lobby | Gift Shop |


Prizes & Awards
My Profile



Active Members
TodayLast 7 Days more...






Resources » Code Snippets » VB.NET Syntax »

Animated closing for windows form in VB.Net


Posted Date: 14 Nov 2008    Resource Type: Code Snippets    Category: VB.NET Syntax
Author: Abraham KuriakoseMember Level: Gold    
Rating: 1 out of 5Points: 5



By using the below code, you can animate for closing the window.


Private Const AW_BLEND = &H80000 'Uses a fade effect. This flag can be used only if hwnd is a top-level window.
Private Declare Function AnimateWindow Lib "user32" (ByVal hwnd As Int32, ByVal dwTime As Int32, ByVal dwFlags As Int32) As Boolean
Dim winHide As Integer = &H10000
Dim winBlend As Integer = &H80000


Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
AnimateWindow(Me.Handle.ToInt32, CInt(500), winHide Or winBlend)
Me.Close()
End Sub




Responses


No responses found. Be the first to respond and make money from revenue sharing program.

Feedbacks      
Popular Tags   What are tags ?   Search Tags  
Sign In to add tags.
Windows form  .  Animation in windows forms  .  Animation  .  Animated closing for windows  .  

Post Feedback


This is a strictly moderated forum. Only approved messages will appear in the site. Please use 'Spell Check' in Google toolbar before you submit.
You must Sign In to post a response.
Next Resource: choosing multiple values from checkbox list and put in database and back from the database to check
Previous Resource: Get the Current working Directory
Return to Discussion Resource Index
Post New Resource
Category: VB.NET Syntax


Post resources and earn money!
 
Related Resources



dotNet Slackers

About Us    Contact Us    Privacy Policy    Terms Of Use