quote:
Originally posted by Mike2
That will only work for your application.
If you want it on top for all windows then you have to use the ShowWindow api if i remember correcly.
I'll post an example when i get home...
eh yeah... but he asked for hiding the mousecursor system-wide, not about a code to show your window alwyas on top (although, that could help him for this application also
)
To keep your window always on top:
code:
Declare Function SetWindowPos Lib "User" (ByVal h%, ByVal hb%, ByVal X%, ByVal Y%, ByVal cx%, ByVal cy%, ByVal f%) As Integer
Const FLAGS = 1
Const HWND_TOPMOST = -1
' Use the above Declaration and Constants along with
' the code in "Form_Load" to make a window remain On Top.
Sub Form_Load ()
'Sets form1 always on top.
Dim Success As Integer
Success% = SetWindowPos(Form1.hWnd, HWND_TOPMOST, 0, 0, 0, 0, FLAGS)
' Change the "0's" above to position the window.
End Sub