Visual Basic > Applications-VBA
Put your application on top
Put your application on top Declare Function SetWindowPos Lib "User" (ByVal hWnd as Integer, ByVal hWndinsertafter as Integer, ByVal x as Integer, ByVal Y as Integer, ByVal cx as Integer, ByVal cy as Integer, ByVal wFlags as Integer) as Integer Global Const HWND_TOPMOST = -1 Global Const HWND_NOTOPMOST = -2 Sub MakeTopMost (frmForm as Form, LX%, LY%, RX%, RY%) dim succes as Long succes = SetWindowPos(frmForm.hWnd, HWND_TOPMOST, LX%, LY%, RX%, RY%, 0) End Sub Sub UnMakeTopMost (frmForm as Form) dim succes as Long succes = SetWindowPos(frmForm.hWnd, HWND_NOTOPMOST, 0, 0, 0, 0, 0) End Sub Return
Visual Basic Codes
ActiveX
Miscellaneous
Applications
Code Snippets
Common Dialogs
Special Effects
Database Stuff
Date Time
Files Drives
Forms
Graphics Games
Internet Stuff
Multimedia
Other
Strings
Windows