Click to See Complete Forum and Search --> : Can I trap the Minimize action by the User in a Form


britto
November 2nd, 1999, 12:57 AM
Hi,
I am working on a project that will be runing on a Win-NT server for all the time ie. 24 Hrs.

If the user minimizes the form the application has to be seen in the system tray some thing similar to Task Manager of Win-Nt.

Thanks in advance,

Britto

Chris Eastwood
November 2nd, 1999, 02:28 AM
You can use code similar to :


private Sub Form_Resize()
If me.WindowState = vbMinimized then
MsgBox "Window is minimized!"
End If
End Sub




- to trap the minimized state of the window. You can then use our own AndyK's code from


http://codeguru.developer.com/bbs/wt/showpost.pl?Board=vb&Number=7460&Search=true&Forum=vb&Words=system%20tray&Match=Whole&Topic=&Searchpage=0&Limit=25

to place an icon in the system tray.


Chris Eastwood

CodeGuru - the website for developers
http://codeguru.developer.com/vb